diff options
author | ctrlaltca <ctrlaltca@gmail.com> | 2014-08-26 16:59:21 +0200 |
---|---|---|
committer | ctrlaltca <ctrlaltca@gmail.com> | 2014-08-26 16:59:21 +0200 |
commit | 74b31be9515eddfa63005d6760614badfaba9fea (patch) | |
tree | 47c952901dcb5eccd6dd8b7c6ee7e0b6bf176510 /tests/FunctionalTests/tickets/tests/Ticket207TestCase.php | |
parent | 2b11341614ac4a15be697fa8acad07055154ac54 (diff) | |
parent | 0c5026b55cde5c104f10686afd8b441568175d38 (diff) |
Backports for Prado 3.2.4
Diffstat (limited to 'tests/FunctionalTests/tickets/tests/Ticket207TestCase.php')
-rwxr-xr-x | tests/FunctionalTests/tickets/tests/Ticket207TestCase.php | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php index cd618a5d..cc993192 100755 --- a/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php +++ b/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php @@ -1,25 +1,28 @@ <?php -class Ticket207TestCase extends PradoGenericSeleniumTest +class Ticket207TestCase extends PradoGenericSelenium2Test { function test() { $base = 'ctl0_Content_'; - $this->open('tickets/index.php?page=Ticket207'); - $this->assertTitle("Verifying Ticket 207"); + $this->url('tickets/index.php?page=Ticket207'); + $this->assertEquals($this->title(), "Verifying Ticket 207"); $this->assertNotVisible("{$base}validator1"); $this->assertNotVisible("{$base}validator2"); - - $this->click("{$base}button1"); - $this->assertAlert('error on text1 fired'); + + $this->byId("{$base}button1")->click(); + + $this->assertEquals('error on text1 fired', $this->alertText()); + $this->acceptAlert(); + $this->assertVisible("{$base}validator1"); $this->assertVisible("{$base}validator2"); - + $this->type("{$base}text1", 'test'); $this->assertVisible("{$base}validator1"); $this->assertVisible("{$base}validator2"); - $this->click("{$base}button1"); + $this->byId("{$base}button1")->click(); $this->assertNotVisible("{$base}validator1"); $this->assertVisible("{$base}validator2"); @@ -27,8 +30,11 @@ class Ticket207TestCase extends PradoGenericSeleniumTest $this->assertNotVisible("{$base}validator1"); $this->assertVisible("{$base}validator2"); - $this->click("{$base}button1"); - $this->assertAlert('error on text1 fired'); + $this->byId("{$base}button1")->click(); + + $this->assertEquals('error on text1 fired', $this->alertText()); + $this->acceptAlert(); + $this->assertVisible("{$base}validator1"); $this->assertVisible("{$base}validator2"); } |