From 5d9f6fc77131d75e6c73a7e57df8d967b6b09215 Mon Sep 17 00:00:00 2001 From: Fabio Bas Date: Mon, 6 Jan 2014 22:34:49 +0100 Subject: Fixed some function tests; start working on porting them to Selenium2 interface --- tests/test_tools/PradoGenericSelenium2Test.php | 49 ++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 tests/test_tools/PradoGenericSelenium2Test.php (limited to 'tests/test_tools/PradoGenericSelenium2Test.php') diff --git a/tests/test_tools/PradoGenericSelenium2Test.php b/tests/test_tools/PradoGenericSelenium2Test.php new file mode 100644 index 00000000..66350e11 --- /dev/null +++ b/tests/test_tools/PradoGenericSelenium2Test.php @@ -0,0 +1,49 @@ +setBrowser(static::$browser); + $this->setBrowserUrl(static::$baseurl); + $this->setSeleniumServerRequestsTimeout(static::$timeout); + } + + public function setUpPage() + { + $this->timeouts()->implicitWait(static::$wait); + } + + protected function open($url) + { + $this->url($url); + } + + protected function tearDown() + { + } + + protected function verifyTextPresent($txt) + { + $this->assertContains($txt, $this->source()); + } + + protected function assertText($id, $txt) + { + $element = $this->byId($id); + $this->assertEquals($txt, $element->text()); + } + + protected function pause($msec) + { + usleep($msec*1000); + } + +} \ No newline at end of file -- cgit v1.2.3