views:

109

answers:

0

My website has a Login page, so it needs to login first to run each html selense test file. The way PHPUnit framework works is creating independent test cases by running each test independently, which means it calls the Setup() function on each test case --> then calls Selenium RC Server--> then creates session id. My Code is below:

require_once 'PHPUnit/Extensions/SeleniumTestCase.php';

class SeleneseTests extends PHPUnit_Extensions_SeleniumTestCase { protected static $seleneseDirectory = '/home/server/Web/phase-four/tests';

protected function setUp() { $this->setBrowser("*firefox"); $this->setBrowserUrl("http://mywebsite.com/"); } }