php - phpUnit in netbeans -


i want have of pros help. well, i've been trying set phpunit in netbeans cannot run tests. whenever run tests error shows , cannot run tests

indextest.php

    <?php class indextest extends phpunit_framework_testcase {     // ...      public function testcanbenegated()     {         // arrange         $a = new index(1);          // act         $b = $a->negate();          // assert         $this->assertequals(-1, $b->getamount());     }      // ... } 

index.php

    <?php class index {     private $amount;      public function __construct($amount)     {         $this->amount = $amount;     }      public function getamount()     {         return $this->amount;     }      public function negate()     {         return new index(-1 * $this->amount);     }      // ... } 

for example, how test codes these?


Comments

Popular posts from this blog

PHPMotion implementation - URL based videos (Hosted on separate location) -

javascript - Using Windows Media Player as video fallback for video tag -

c# - Unity IoC Lifetime per HttpRequest for UserStore -