summaryrefslogtreecommitdiff
path: root/tests/FunctionalTests
diff options
context:
space:
mode:
Diffstat (limited to 'tests/FunctionalTests')
-rwxr-xr-xtests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php10
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/PagerTestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php6
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php2
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php4
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php4
-rwxr-xr-xtests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php4
11 files changed, 22 insertions, 18 deletions
diff --git a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
index 4f210608..257917ec 100755
--- a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
@@ -5,6 +5,7 @@ class QuickstartActiveCheckBoxTestCase extends PradoGenericSeleniumTest
{
function test ()
{
+ $this->setSpeed(500);
$this->open("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveCheckBox.Home&notheme=true&lang=en", "");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -52,5 +53,6 @@ class QuickstartActiveCheckBoxTestCase extends PradoGenericSeleniumTest
$this->click("//input[@name='ctl0\$body\$CheckBox2']", "");
$this->verifyVisible('ctl0_body_ctl5');
$this->assertChecked("//input[@name='ctl0\$body\$CheckBox2']");
+ $this->setSpeed(0);
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
index 0473d6d5..7efd69cc 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
@@ -29,7 +29,7 @@ class QuickstartDataGrid2TestCase extends PradoGenericSeleniumTest
$this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@checked','regexp:true|checked');
$this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@disabled','regexp:true|disabled');
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl5@checked','regexp:true|checked');
- $this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl6_ctl5").hasAttribute("checked")'), 'false');
$this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@disabled','regexp:true|disabled');
// verify ratings
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
index 47762d7d..2cdace20 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
@@ -27,7 +27,7 @@ class QuickstartDataGrid3TestCase extends PradoGenericSeleniumTest
$this->verifyTextPresent("Design Pattern: Elements of Reusable Object-Oriented Software", "");
$this->verifyTextPresent("Addison Wesley Professional", "");
$this->verifyTextPresent("$57.04", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl4@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl2_ctl4").hasAttribute("checked")'), 'false');
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl4@disabled','regexp:true|disabled');
//$this->verifyElementPresent("//img[@src='images/star1.gif']",'');
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
index 9a212dd8..702b997e 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
@@ -15,14 +15,14 @@ class QuickstartDataGrid4TestCase extends PradoGenericSeleniumTest
// verify sorting
$this->clickAndWait("link=Book Title", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl1_ctl5").hasAttribute("checked")'), 'false');
$this->clickAndWait("link=Publisher", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl6_ctl5").hasAttribute("checked")'), 'false');
$this->clickAndWait("link=Price", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl2_ctl5").hasAttribute("checked")'), 'false');
$this->clickAndWait("link=In-stock", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl1_ctl5").hasAttribute("checked")'), 'false');
$this->clickAndWait("link=Rating", "");
- $this->verifyAttribute('ctl0_body_DataGrid_ctl4_ctl5@checked','regexp:false|null');
+ $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl4_ctl5").hasAttribute("checked")'), 'false');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php b/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
index 4a31a0be..2b47456e 100755
--- a/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
@@ -32,6 +32,6 @@ class QuickstartMultiViewTestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0$body$ctl7');
// view 2 : check if dropdownlist maintains state
- $this->verifySelected('ctl0$body$DropDownList', "label=Blue");
+ $this->assertSelected('ctl0$body$DropDownList', "Blue");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php b/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
index 9ffbdcf6..a1fefed6 100755
--- a/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
@@ -43,7 +43,7 @@ class QuickstartPagerTestCase extends PradoGenericSeleniumTest
$this->verifyTextNotPresent('ITN002','');
$this->verifyTextNotPresent('ITN005','');
- $this->verifySelected("ctl0_body_Pager3_ctl0","label=2");
+ $this->assertSelected("ctl0_body_Pager3_ctl0","2");
$this->selectAndWait("ctl0_body_Pager3_ctl0", "label=5");
$this->verifyTextPresent('ITN009','');
$this->verifyTextPresent('ITN010','');
diff --git a/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php b/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
index 86a4bf86..22031235 100755
--- a/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
@@ -24,10 +24,10 @@ class QuickstartRadioButtonTestCase extends PradoGenericSeleniumTest
// a radiobutton causing validation on a textbox
$this->verifyNotVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
-// $this->pause(1000);
+ $this->pause(1000);
$this->verifyVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
-// $this->pause(1000);
+ $this->pause(1000);
$this->verifyVisible('ctl0_body_ctl3');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
@@ -36,7 +36,7 @@ class QuickstartRadioButtonTestCase extends PradoGenericSeleniumTest
// a radiobutton validated by a required field validator
$this->verifyNotVisible('ctl0_body_ctl6');
$this->click("//input[@type='submit' and @value='Submit']", "");
-// $this->pause(1000);
+ $this->pause(1000);
$this->verifyVisible('ctl0_body_ctl6');
$this->click("//input[@name='ctl0\$body\$RadioButton' and @value='ctl0\$body\$RadioButton']", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
diff --git a/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php b/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
index b17f9e9b..a3464702 100755
--- a/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
@@ -48,7 +48,7 @@ class QuickstartTextBoxTestCase extends PradoGenericSeleniumTest
// SafeText
$this->verifyText("ctl0_body_Output","test");
- $this->typeAndWait("ctl0\$body\$TextBox2","<a href=javascript:xxx>malicious code</a>");
+ $this->typeAndWait("ctl0\$body\$TextBox2","<a href=javascript:xxx>malicious code</a>");
$this->verifyText("ctl0_body_Output","malicious code");
// password
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
index 3cbf1bd3..f2b8ad6e 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
@@ -19,7 +19,7 @@ class QuickstartWizard4TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
// step 1
- $this->verifySelected('ctl0_body_Wizard1_DropDownList1', "label=Cyan");
+ $this->assertSelected('ctl0_body_Wizard1_DropDownList1', "Cyan");
$this->select('ctl0_body_Wizard1_DropDownList1', "label=Black");
$this->clickAndWait('ctl0_body_Wizard1_ctl4_ctl0');
@@ -30,7 +30,7 @@ class QuickstartWizard4TestCase extends PradoGenericSeleniumTest
// step 1
$this->verifyTextPresent('Step 1 of 3');
- $this->verifySelected('ctl0_body_Wizard1_DropDownList1', "label=Black");
+ $this->assertSelected('ctl0_body_Wizard1_DropDownList1', "Black");
$this->clickAndWait('ctl0_body_Wizard1_ctl4_ctl0');
// step 2
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
index debd8d43..eb5edb3b 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
@@ -21,11 +21,11 @@ class QuickstartWizard5TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0$body$Wizard1$ctl6$ctl0');
// step 1
- $this->verifySelected('ctl0_body_Wizard1_DropDownList1','label=Cyan');
+ $this->assertSelected('ctl0_body_Wizard1_DropDownList1','Cyan');
$this->clickAndWait('ctl0_body_Wizard1_SideBarList_ctl1_SideBarButton');
// step 2
- $this->verifySelected('ctl0_body_Wizard1_Step2_DropDownList2','label=Football');
+ $this->assertSelected('ctl0_body_Wizard1_Step2_DropDownList2','Football');
$this->clickAndWait('ctl0$body$Wizard1$ctl6$ctl1');
// step 3
diff --git a/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php b/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
index 5ec5f065..7ec220f0 100755
--- a/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
@@ -7,6 +7,7 @@ class DataTypeValidatorTestCase extends PradoGenericSeleniumTest
{
function test()
{
+ $this->setSpeed(500);
$base = "ctl0_Content_";
$this->open("validators/index.php?page=DataTypeValidator", "");
$this->verifyTextPresent("Data Type Validator Tests", "");
@@ -15,7 +16,7 @@ class DataTypeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
$this->assertNotVisible("{$base}validator3");
-
+
$this->type("{$base}textbox1", "a");
$this->type("{$base}textbox2", "b");
$this->type("{$base}textbox3", "c");
@@ -42,6 +43,7 @@ class DataTypeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
$this->assertVisible("{$base}validator3");
+ $this->setSpeed(0);
}
}