We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

unit test

Hi, I am new to phalcon and wants to implement unit test cases. I tried to follow from below link, but it doesn't work for me. https://docs.phalcon.io/en/latest/reference/unit-testing.html Examples to do a unit test and functional test with phpunit and phalcon, would be very apreciated :)



2.2k

but it doesn't work for me.

What do you mean? What happend? The doc is an example to do a unit test.

edited Jun '15

I tried to follow from below link, but it doesn't work for me.

+1 PHP Fatal error: Class 'UnitTestCase' not found in /home/Dev/web/testproject/public_html/tests/testsTestUnitTest.php on line 6

$loader->registerNamespaces(array( 'Phalcon' => '/home/Dev/libs/incubator/Library/Phalcon/' ));

does not help

btw. i dont find "autoload.php" at incubator repository which used here:

// required for phalcon/incubator include DIR . "/../vendor/autoload.php";