How i should declare function setUp in my test, because when i use this
class IndexControllerTest extends Phalcon\Test\UnitTestCase {
protected $_account;
public function setUp(){
$this->_account = new IndexController();
}
public function testBalanceIsZeroWhenOpenAccount(){
$balance = $this->_account->getBalance();
$this->assertEquals(0,$balance,'Balance not zero !');
}
}
I recive this: Declaration of IndexControllerTest::setUp() should be compatible with Phalcon\Test\UnitTestCase::setUp
I want to tets one of my controller i use this PHPunit xml config:
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="./TestHelper.php"
backupGlobals="false"
backupStaticAttributes="false"
verbose="true"
colors="false"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false"
syntaxCheck="true">
<testsuite name="Phalcon - Testsuite">
<directory>./</directory>
</testsuite>
</phpunit>