2

When I run even a sample test, either in Netbeans IDE of from the command line, e.g.:

class WebTest extends PHPUnit_Extensions_Selenium2TestCase
{
protected function setUp()
{
    $this->setBrowser('firefox');
    $this->setBrowserUrl('http://www.example.com/');
}

public function testTitle()
{
    $this->url('http://www.example.com/');
    $this->assertEquals('Example WWW Page', $this->title());
}

}

I get the PHPUnit response, but it doesn't seem to be communication with the Selenium server as no browser window was created.

PHPUnit 3.6.10 by Sebastian Bergmann.

Configuration read from /var/www/gcd/framework/yii/gadget/protected/tests/phpunit.xml

F

Time: 1 second, Memory: 10.50Mb

There was 1 failure:

1) WebTest::testTitle
Failed asserting that null matches expected 'Example WWW Page'.

Using PHPUnit 3.6.10 and selenium-server-standalone-2.21.0

Anyone any ideas?

1
  • Turns out, if you run PHPUnit with sudo, it works! Doh! Commented May 24, 2012 at 11:00

1 Answer 1

2

Turns out, if you run PHPUnit with sudo, it works! Doh!

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.