summaryrefslogtreecommitdiff
path: root/tests/FunctionalTests
diff options
context:
space:
mode:
Diffstat (limited to 'tests/FunctionalTests')
-rwxr-xr-xtests/FunctionalTests/active-controls/protected/pages/ActiveDatePicker.page2
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveButtonTestCase.php11
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveCheckBoxListTestCase.php32
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveCheckBoxTestCase.php53
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveControlExpressTagTestCase.php13
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveDatePickerTestCase.php157
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveDropDownListTestCase.php39
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveHiddenFieldTestCase.php21
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveHyperLinkTestCase.php11
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveImageButtonTestCase.php9
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveLinkButtonTestCase.php13
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveListBoxMasterTestCase.php40
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveListBoxTestCase.php41
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActivePanelTestCase.php7
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveRadioButtonListTestCase.php28
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ActiveRadioButtonTestCase.php63
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/AutoCompleteTestCase.php45
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/CalculatorTestCase.php27
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/CallbackAdapterTestCase.php28
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/CallbackOptionsTestCase.php13
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/CustomTemplateTestCase.php17
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php17
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/EventTriggerTestCase.php17
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/NestedActiveControlsTestCase.php21
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/PopulateListTestCase.php21
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/PostLoadingTestCase.php9
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ReplaceContentTestCase.php74
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/TextBoxCallbackTestCase.php13
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/TextBoxGroupValidationTestCase.php19
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/TimeTriggeredCallbackTestCase.php13
-rwxr-xr-xtests/FunctionalTests/active-controls/tests/ValueTriggerCallbackTestCase.php17
-rwxr-xr-xtests/FunctionalTests/active-controlstests/ActiveRatingListTestCase.php304
-rwxr-xr-xtests/FunctionalTests/features/protected/pages/I18N/BasicI18N.php16
-rwxr-xr-xtests/FunctionalTests/features/tests/MyTestCase.php4
-rwxr-xr-xtests/FunctionalTests/quickstart/ActiveControls/ActiveButtonTestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php31
-rwxr-xr-xtests/FunctionalTests/quickstart/ActiveControls/ActiveCustomValidatorTestCase.php4
-rwxr-xr-xtests/FunctionalTests/quickstart/Advanced/I18N.php86
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/BulletedListTestCase.php32
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/ButtonTestCase.php18
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/CheckBoxListTestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/CheckBoxTestCase.php30
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid1TestCase.php34
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php40
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php33
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid5TestCase.php124
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataGrid6TestCase.php62
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataList1TestCase.php26
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DataList2TestCase.php41
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/DropDownListTestCase.php36
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/ExpressionTestCase.php6
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/HtmlAreaTestCase.php4
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/HyperLinkTestCase.php14
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/ImageButtonTestCase.php14
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/ImageTestCase.php14
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/LabelTestCase.php12
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/LinkButtonTestCase.php10
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/ListBoxTestCase.php39
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/PagerTestCase.php66
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/PanelTestCase.php14
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/RadioButtonListTestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php30
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Repeater1TestCase.php32
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Repeater2TestCase.php48
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Repeater3TestCase.php22
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/StatementsTestCase.php6
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/TabPanelTestCase.php42
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/TableTestCase.php18
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php44
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard1TestCase.php16
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard2TestCase.php16
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard3TestCase.php20
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php18
-rwxr-xr-xtests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php14
-rwxr-xr-xtests/FunctionalTests/quickstart/Fundamentals/HangmanTestCase.php22
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Issue120TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Issue216TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket121TestCase.php12
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket163TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket169TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket191TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket205TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket207TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket21TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket220TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket225TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket227TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket239TestCase.php64
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket246TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket274TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket278TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket27TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket284TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket285TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket28TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket290TestCase.php21
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket433TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket439TestCase.php9
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket463TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket470TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket477TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket488TestCase.php35
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket504TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket507TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket521TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket526TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket528TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket535TestCase.php14
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket538TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket54TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket573TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket578TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket585TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket586TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket587TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket592TestCase.php22
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket595TestCase.php28
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket622TestCase.php14
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket653TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket656TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket659TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket660TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket669TestCase.php52
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket670TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket671TestCase.php32
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket671_reopenedTestCase.php24
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket679TestCase.php22
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket691TestCase.php14
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket698TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket700TestCase.php24
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket703TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket708TestCase.php14
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket719TestCase.php12
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket722TestCase.php13
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket72TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket745TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket769TestCase.php12
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket785TestCase.php16
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket823TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket828TestCase.php4
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket849TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket876TestCase.php14
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket886TestCase.php6
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket897TestCase.php10
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket900TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket922TestCase.php8
-rwxr-xr-xtests/FunctionalTests/tickets/tests/Ticket93TestCase.php8
-rwxr-xr-xtests/FunctionalTests/validators/protected/pages/ListControl.page28
-rwxr-xr-xtests/FunctionalTests/validators/tests/ButtonTestCase.php60
-rwxr-xr-xtests/FunctionalTests/validators/tests/CheckBoxTestCase.php60
-rwxr-xr-xtests/FunctionalTests/validators/tests/CompareValidatorTestCase.php18
-rwxr-xr-xtests/FunctionalTests/validators/tests/ConditionalValidationTestCase.php6
-rwxr-xr-xtests/FunctionalTests/validators/tests/CustomValidatorTestCase.php6
-rwxr-xr-xtests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php20
-rwxr-xr-xtests/FunctionalTests/validators/tests/DatePickerTestCase.php6
-rwxr-xr-xtests/FunctionalTests/validators/tests/ImageButtonTestCase.php60
-rwxr-xr-xtests/FunctionalTests/validators/tests/LinkButtonTestCase.php60
-rwxr-xr-xtests/FunctionalTests/validators/tests/ListControlTestCase.php9
-rwxr-xr-xtests/FunctionalTests/validators/tests/RangeValidatorTestCase.php52
-rwxr-xr-xtests/FunctionalTests/validators/tests/RegExpValidatorTestCase.php6
-rwxr-xr-xtests/FunctionalTests/validators/tests/RequiredFieldTestCase.php6
-rwxr-xr-xtests/FunctionalTests/validators/tests/RequiredListTestCase.php4
-rwxr-xr-xtests/FunctionalTests/validators/tests/ValidationSummaryTestCase.php34
165 files changed, 1855 insertions, 1823 deletions
diff --git a/tests/FunctionalTests/active-controls/protected/pages/ActiveDatePicker.page b/tests/FunctionalTests/active-controls/protected/pages/ActiveDatePicker.page
index 8d38c758..ce40e1cb 100755
--- a/tests/FunctionalTests/active-controls/protected/pages/ActiveDatePicker.page
+++ b/tests/FunctionalTests/active-controls/protected/pages/ActiveDatePicker.page
@@ -1,12 +1,12 @@
<com:TContent ID="Content">
<h1>TActiveDatePicker test</h1>
<p>
-<com:TActiveDatePicker ID="datepicker" DateFormat="MM-dd-yyyy" OnCallback="testDatePicker"/>
<com:TActiveLabel ID="status" /><br/>
<com:TActiveButton ID="decreaseButton" OnClick="decrease" Text="-1" OnCallback="testDatePicker"/>
<com:TActiveButton ID="todayButton" OnClick="today" Text="Today" OnCallback="testDatePicker"/>
<com:TActiveButton ID="increaseButton" OnClick="increase" Text="+1" OnCallback="testDatePicker"/>
<com:TButton ID="toggleButton" OnClick="toggleMode" Text="Toggle input mode (postback)"/>
+<com:TActiveDatePicker ID="datepicker" DateFormat="MM-dd-yyyy" OnCallback="testDatePicker"/>
</p>
<p>
ShowCalendar=false
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveButtonTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveButtonTestCase.php
index 880c46fe..a98c14be 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveButtonTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveButtonTestCase.php
@@ -4,11 +4,12 @@ class ActiveButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveButtonTest");
- $this->verifyTextPresent("TActiveButton Functional Test");
- $this->assertText("label1", "Label 1");
- $this->clickOnElement("button2");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveButtonTest");
+ $this->assertTextPresent("TActiveButton Functional Test");
+ $this->assertText("{$base}label1", "Label 1");
+ $this->clickOnElement("{$base}button2");
$this->pause(800);
- $this->assertText("label1", "Button 1 was clicked using callback!");
+ $this->assertText("{$base}label1", "Button 1 was clicked using callback!");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxListTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxListTestCase.php
index 312b8443..e1e0ba4b 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxListTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxListTestCase.php
@@ -1,55 +1,57 @@
<?php
-class ActiveCheckBoxListTestCase extends PradoGenericSeleniumTest
+class ActiveCheckBoxListTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=TActiveCheckBoxListTest");
- $this->verifyTextPresent("TActiveCheckBoxList Test Case");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=TActiveCheckBoxListTest");
+ $this->assertTextPresent("TActiveCheckBoxList Test Case");
- $this->assertText("label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
$this->assertCheckBoxes(array(1,2,3));
- $this->click("button2");
+ $this->click("{$base}button2");
$this->pause(800);
$this->assertCheckBoxes(array());
- $this->click("button3");
+ $this->click("{$base}button3");
$this->pause(800);
$this->assertCheckBoxes(array(0));
- $this->click("button4");
+ $this->click("{$base}button4");
$this->pause(800);
$this->assertCheckBoxes(array(4));
- $this->click("button5");
+ $this->click("{$base}button5");
$this->pause(800);
$this->assertCheckBoxes(array(1,4));
- $this->click("list1_c2");
+ $this->click("{$base}list1_c2");
$this->pause(800);
- $this->assertText("label1", "Selection: value 2, value 3, value 5");
+ $this->assertText("{$base}label1", "Selection: value 2, value 3, value 5");
- $this->click("list1_c2");
+ $this->click("{$base}list1_c2");
$this->pause(800);
- $this->assertText("label1", "Selection: value 2, value 5");
+ $this->assertText("{$base}label1", "Selection: value 2, value 5");
}
function assertCheckBoxes($checks, $total = 5)
{
+ $base='ctl0_Content_';
for($i = 0; $i < $total; $i++)
{
if(in_array($i, $checks))
- $this->assertChecked("list1_c{$i}");
+ $this->assertChecked("{$base}list1_c{$i}");
else
- $this->assertNotChecked("list1_c{$i}");
+ $this->assertNotChecked("{$base}list1_c{$i}");
}
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxTestCase.php
index 6f235273..beedebc7 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveCheckBoxTestCase.php
@@ -1,59 +1,60 @@
<?php
-class ActiveCheckBoxTestCase extends PradoGenericSeleniumTest
+class ActiveCheckBoxTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveCheckBoxTest");
- $this->verifyTextPresent("Active CheckBox Test");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveCheckBoxTest");
+ $this->assertTextPresent("Active CheckBox Test");
- $this->assertText("checkbox1_label", "CheckBox 1");
- $this->assertText("checkbox2_label", "CheckBox 2");
- $this->assertText('label1', 'Label 1');
+ $this->assertText("{$base}checkbox1_label", "CheckBox 1");
+ $this->assertText("{$base}checkbox2_label", "CheckBox 2");
+ $this->assertText("{$base}label1", 'Label 1');
- $this->click("change_text1");
+ $this->click("{$base}change_text1");
$this->pause(800);
- $this->assertText('checkbox1_label', 'Hello CheckBox 1');
+ $this->assertText("{$base}checkbox1_label", 'Hello CheckBox 1');
- $this->click("change_text2");
+ $this->click("{$base}change_text2");
$this->pause(800);
- $this->assertText('checkbox2_label', 'CheckBox 2 World');
+ $this->assertText("{$base}checkbox2_label", 'CheckBox 2 World');
//check box 1
- $this->click('change_checked1');
+ $this->click("{$base}change_checked1");
$this->pause(800);
- $this->assertChecked('checkbox1');
+ $this->assertChecked("{$base}checkbox1");
- $this->click('change_checked1');
+ $this->click("{$base}change_checked1");
$this->pause(800);
- $this->assertNotChecked('checkbox1');
+ $this->assertNotChecked("{$base}checkbox1");
//check box 2
- $this->click('change_checked2');
+ $this->click("{$base}change_checked2");
$this->pause(800);
- $this->assertChecked('checkbox2');
+ $this->assertChecked("{$base}checkbox2");
- $this->click('change_checked2');
+ $this->click("{$base}change_checked2");
$this->pause(800);
- $this->assertNotChecked('checkbox2');
+ $this->assertNotChecked("{$base}checkbox2");
//click checkbox 1
- $this->click("checkbox1");
+ $this->click("{$base}checkbox1");
$this->pause(800);
- $this->assertText("label1", "Label 1:Hello CheckBox 1 Checked");
+ $this->assertText("{$base}label1", "Label 1:Hello CheckBox 1 Checked");
- $this->click("checkbox1");
+ $this->click("{$base}checkbox1");
$this->pause(800);
- $this->assertText("label1", "Label 1:Hello CheckBox 1 Not Checked");
+ $this->assertText("{$base}label1", "Label 1:Hello CheckBox 1 Not Checked");
//click checkbox 2
- $this->click("checkbox2");
+ $this->click("{$base}checkbox2");
$this->pause(800);
- $this->assertText("label1", "Label 1:CheckBox 2 World Checked");
+ $this->assertText("{$base}label1", "Label 1:CheckBox 2 World Checked");
- $this->click("checkbox2");
+ $this->click("{$base}checkbox2");
$this->pause(800);
- $this->assertText("label1", "Label 1:CheckBox 2 World Not Checked");
+ $this->assertText("{$base}label1", "Label 1:CheckBox 2 World Not Checked");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveControlExpressTagTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveControlExpressTagTestCase.php
index 75b86e19..d5c8b4f0 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveControlExpressTagTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveControlExpressTagTestCase.php
@@ -1,18 +1,19 @@
<?php
-class ActiveControlExpressionTagTestCase extends PradoGenericSeleniumTest
+class ActiveControlExpressionTagTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('active-controls/index.php?page=ActiveControlExpressionTag');
+ $base='ctl0_Content_';
+ $this->url('active-controls/index.php?page=ActiveControlExpressionTag');
$this->assertTextPresent('Active Control With Expression Tag Test');
$this->assertTextNotPresent('Text box content:');
- $this->type('textbox1', 'Hello world');
- $this->click('button1');
+ $this->type("{$base}textbox1", 'Hello world');
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertText('repeats', 'result - 1 result - two');
- $this->assertText('contents', 'Text box content: Hello world');
+ $this->assertText("repeats", 'result - 1 result - two');
+ $this->assertText("contents", 'Text box content: Hello world');
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveDatePickerTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveDatePickerTestCase.php
index be0a6fb4..0d6e2203 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveDatePickerTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveDatePickerTestCase.php
@@ -1,118 +1,119 @@
<?php
-class ActiveDatePickerTestCase extends PradoGenericSeleniumTest
+class ActiveDatePickerTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveDatePicker");
- $this->verifyTextPresent("TActiveDatePicker test");
- $this->verifyText("status", "");
- $this->verifyValue("datepicker", date('m-d-Y'));
- $this->click("increaseButton");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveDatePicker");
+ $this->assertTextPresent("TActiveDatePicker test");
+ $this->assertText("{$base}status", "");
+ $this->assertValue("{$base}datepicker", date('m-d-Y'));
+ $this->click("{$base}increaseButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y', strtotime('+ 1 day')));
- $this->verifyText("status", date('m-d-Y', strtotime('+ 1 day')));
- $this->click("increaseButton");
+ $this->assertValue("{$base}datepicker", date('m-d-Y', strtotime('+ 1 day')));
+ $this->assertText("{$base}status", date('m-d-Y', strtotime('+ 1 day')));
+ $this->click("{$base}increaseButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y', strtotime('+ 2 day')));
- $this->verifyText("status", date('m-d-Y', strtotime('+ 2 day')));
- $this->click("todayButton");
+ $this->assertValue("{$base}datepicker", date('m-d-Y', strtotime('+ 2 day')));
+ $this->assertText("{$base}status", date('m-d-Y', strtotime('+ 2 day')));
+ $this->click("{$base}todayButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y'));
- $this->verifyText("status", date('m-d-Y'));
- $this->click("decreaseButton");
+ $this->assertValue("{$base}datepicker", date('m-d-Y'));
+ $this->assertText("{$base}status", date('m-d-Y'));
+ $this->click("{$base}decreaseButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y', strtotime('- 1 day')));
- $this->verifyText("status", date('m-d-Y', strtotime('- 1 day')));
- $this->click("datepicker");
+ $this->assertValue("{$base}datepicker", date('m-d-Y', strtotime('- 1 day')));
+ $this->assertText("{$base}status", date('m-d-Y', strtotime('- 1 day')));
+ $this->click("{$base}datepicker");
$this->pause(800);
$this->click("css=input.todayButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y'));
- $this->verifyText("status", date('m-d-Y'));
+ $this->assertValue("{$base}datepicker", date('m-d-Y'));
+ $this->assertText("{$base}status", date('m-d-Y'));
$this->click("css=input.nextMonthButton");
$this->pause(800);
- $this->verifyValue("datepicker", date('m-d-Y', strtotime('+ 1 month')));
- $this->verifyText("status", date('m-d-Y', strtotime('+1 month')));
-
- $this->click('toggleButton');
+ $this->assertValue("{$base}datepicker", date('m-d-Y', strtotime('+ 1 month')));
+ $this->assertText("{$base}status", date('m-d-Y', strtotime('+1 month')));
+
+ $this->click("{$base}toggleButton");
$this->pause(2000);
-
- $this->click("todayButton");
+
+ $this->click("{$base}todayButton");
$this->pause(800);
- $this->assertSelected("datepicker_month", date('m'));
- $this->verifyText("status", date('m-d-Y'));
-
- $this->click("increaseButton");
+ $this->assertSelected("{$base}datepicker_month", date('m'));
+ $this->assertText("{$base}status", date('m-d-Y'));
+
+ $this->click("{$base}increaseButton");
$this->pause(800);
$dateToCheck=strtotime('+ 1 day');
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
- $this->click("increaseButton");
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
+ $this->click("{$base}increaseButton");
$this->pause(800);
$dateToCheck=strtotime('+ 2 day');
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
- $this->click("todayButton");
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
+ $this->click("{$base}todayButton");
$this->pause(800);
$dateToCheck=time();
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
- $this->click("decreaseButton");
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
+ $this->click("{$base}decreaseButton");
$this->pause(800);
$dateToCheck=strtotime('- 1 day');
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
- $this->click("datepickerbutton");
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
+ $this->click("{$base}datepickerbutton");
$this->pause(800);
$this->click("css=input.todayButton");
$this->pause(800);
$dateToCheck=time();
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
$this->click("css=input.nextMonthButton");
$this->pause(800);
$dateToCheck=strtotime('+ 1 month');
- $this->assertSelected("datepicker_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker_year", date('Y', $dateToCheck));
- $this->verifyText("status", date('m-d-Y', $dateToCheck));
-
- $this->click('ctl1');
- $this->pause(800);
-
- $this->verifyText("status2", "");
+ $this->assertSelected("{$base}datepicker_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker_year", date('Y', $dateToCheck));
+ $this->assertText("{$base}status", date('m-d-Y', $dateToCheck));
+
+ $this->click('ctl0_ctl1');
+ $this->pause(800);
+
+ $this->assertText("{$base}status2", "");
$dateToCheck=time();
- $this->assertSelected("datepicker2_month", date('m', $dateToCheck));
- $this->assertSelected("datepicker2_day", date('d', $dateToCheck));
- $this->assertSelected("datepicker2_year", date('Y', $dateToCheck));
- $this->select("datepicker2_year", date('Y')+1);
+ $this->assertSelected("{$base}datepicker2_month", date('m', $dateToCheck));
+ $this->assertSelected("{$base}datepicker2_day", date('d', $dateToCheck));
+ $this->assertSelected("{$base}datepicker2_year", date('Y', $dateToCheck));
+ $this->select("{$base}datepicker2_year", date('Y')+1);
$this->pause(800);
$dateToCheck=mktime(0,0,0,(int)date('m'),(int)date('d'), date('Y')+1);
- $this->verifyText("status2", date('m-d-Y', $dateToCheck));
+ $this->assertText("{$base}status2", date('m-d-Y', $dateToCheck));
- $this->verifyText("status3", "");
+ $this->assertText("{$base}status3", "");
$dateToCheck=time();
- $this->assertSelected("datepicker3_month", date('F', $dateToCheck));
- $this->assertSelected("datepicker3_year", date('Y', $dateToCheck));
- $this->select("datepicker3_year", date('Y')+1);
+ $this->assertSelected("{$base}datepicker3_month", date('F', $dateToCheck));
+ $this->assertSelected("{$base}datepicker3_year", date('Y', $dateToCheck));
+ $this->select("{$base}datepicker3_year", date('Y')+1);
$this->pause(800);
$dateToCheck=mktime(0,0,0,(int)date('m'),(int)date('d'), date('Y')+1);
- $this->verifyText("status3", date('m/Y', $dateToCheck));
+ $this->assertText("{$base}status3", date('m/Y', $dateToCheck));
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveDropDownListTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveDropDownListTestCase.php
index a54cbd75..f3bc8dc8 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveDropDownListTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveDropDownListTestCase.php
@@ -1,45 +1,46 @@
<?php
-class ActiveDropDownListTestCase extends PradoGenericSeleniumTest
+class ActiveDropDownListTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveDropDownList");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveDropDownList");
$this->assertTextPresent('Active Drop Down List Test Case');
- $this->assertText("label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertSelected("list1", "item 4");
+ $this->assertSelected("{$base}list1", "item 4");
- $this->click("button2");
+ $this->click("{$base}button2");
$this->pause(800);
- $this->assertSelectedIndex("list1", 0);
+ $this->assertSelectedValue("{$base}list1", 'value 1');
- $this->click("button3");
+ $this->click("{$base}button3");
$this->pause(800);
- $this->assertSelected("list1", "item 2");
+ $this->assertSelected("{$base}list1", "item 2");
- $this->assertText("label1", "Selection 1: value 1");
+ $this->assertText("{$base}label1", "Selection 1: value 1");
- $this->select("list1", "item 1");
+ $this->select("{$base}list1", "item 1");
$this->pause(800);
- $this->select("list2", "value 1 - item 4");
+ $this->select("{$base}list2", "value 1 - item 4");
$this->pause(800);
- $this->assertText("label2", "Selection 2: value 1 - item 4");
+ $this->assertText("{$base}label2", "Selection 2: value 1 - item 4");
- $this->select("list1", "item 3");
+ $this->select("{$base}list1", "item 3");
$this->pause(800);
- $this->select("list2", "value 3 - item 5");
+ $this->select("{$base}list2", "value 3 - item 5");
$this->pause(800);
- $this->assertText("label2", "Selection 2: value 3 - item 5");
+ $this->assertText("{$base}label2", "Selection 2: value 3 - item 5");
- $this->click('button4');
+ $this->click("{$base}button4");
$this->pause(800);
- $this->assertSelected('list1', 'item 3');
+ $this->assertSelected("{$base}list1", 'item 3');
$this->pause(300);
- $this->assertSelected('list2', 'value 3 - item 3');
+ $this->assertSelected("{$base}list2", 'value 3 - item 3');
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveHiddenFieldTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveHiddenFieldTestCase.php
index b8c02868..2aedee05 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveHiddenFieldTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveHiddenFieldTestCase.php
@@ -1,22 +1,23 @@
<?php
-class ActiveHiddenFieldTestCase extends PradoGenericSeleniumTest
+class ActiveHiddenFieldTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveHiddenFieldTest");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveHiddenFieldTest");
$fieldEmpty = 'No longer empty';
$fieldUsed = 'My value';
-
- $this->verifyTextPresent('Value of current hidden field');
- $this->click('Button1');
+
+ $this->assertTextPresent('Value of current hidden field');
+ $this->click("{$base}Button1");
$this->pause(800);
- $this->assertText('ResponseLabel', $fieldEmpty);
- $this->click('Button2');
+ $this->assertText("{$base}ResponseLabel", $fieldEmpty);
+ $this->click("{$base}Button2");
$this->pause(800);
- $this->assertText('ResponseLabel', $fieldUsed);
- $this->click('Button3');
+ $this->assertText("{$base}ResponseLabel", $fieldUsed);
+ $this->click("{$base}Button3");
$this->pause(800);
- $this->assertText('ResponseLabel', $fieldEmpty.'|'.$fieldUsed);
+ $this->assertText("{$base}ResponseLabel", $fieldEmpty.'|'.$fieldUsed);
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveHyperLinkTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveHyperLinkTestCase.php
index bfcdd206..47a90851 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveHyperLinkTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveHyperLinkTestCase.php
@@ -1,16 +1,17 @@
<?php
-class ActiveHyperLinkTestCase extends PradoGenericSeleniumTest
+class ActiveHyperLinkTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveHyperLinkTest");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveHyperLinkTest");
$this->assertTextPresent("Active HyperLink Test Case");
- $this->assertText("link1", "Link 1");
+ $this->assertText("{$base}link1", "Link 1");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertText("link1", "Pradosoft.com");
+ $this->assertText("{$base}link1", "Pradosoft.com");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveImageButtonTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveImageButtonTestCase.php
index 2989ab27..0d9f219d 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveImageButtonTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveImageButtonTestCase.php
@@ -1,13 +1,14 @@
<?php
-class ActiveImageButtonTestCase extends PradoGenericSeleniumTest
+class ActiveImageButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveImageButtonTest");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveImageButtonTest");
$this->assertTextPresent("TActiveImageButton Functional Test");
- $this->assertText("label1", "Label 1");
- $this->click("image1");
+ $this->assertText("{$base}label1", "Label 1");
+ $this->click("{$base}image1");
$this->pause(800);
//unable to determine mouse position
$this->assertTextPresent("regexp:Image clicked at x=\d+, y=\d+");
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveLinkButtonTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveLinkButtonTestCase.php
index 88cdf15e..3e67b516 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveLinkButtonTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveLinkButtonTestCase.php
@@ -1,14 +1,15 @@
<?php
-class ActiveLinkButtonTestCase extends PradoGenericSeleniumTest
+class ActiveLinkButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveLinkButtonTest");
- $this->verifyTextPresent("TActiveLinkButton Functional Test");
- $this->assertText("label1", "Label 1");
- $this->click("button2");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveLinkButtonTest");
+ $this->assertTextPresent("TActiveLinkButton Functional Test");
+ $this->assertText("{$base}label1", "Label 1");
+ $this->click("{$base}button2");
$this->pause(800);
- $this->assertText("label1", "Button 1 was clicked using callback!");
+ $this->assertText("{$base}label1", "Button 1 was clicked using callback!");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveListBoxMasterTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveListBoxMasterTestCase.php
index 911e3cc7..31b80bff 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveListBoxMasterTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveListBoxMasterTestCase.php
@@ -1,48 +1,48 @@
<?php
-class ActiveListBoxMasterTestCase extends PradoGenericSeleniumTest
+class ActiveListBoxMasterTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveListBoxMasterTest");
+ $this->url("active-controls/index.php?page=ActiveListBoxMasterTest");
$this->assertTextPresent('Active List Box Functional Test');
$base = 'ctl0_body_';
- $this->assertText($base."label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->click($base."button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels($base.'list1'), array('item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 3', 'item 4'));
- $this->click($base.'button3');
+ $this->click("{$base}button3");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels($base.'list1'), array('item 1'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 1'));
- $this->click($base.'button4');
+ $this->click("{$base}button4");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels($base.'list1'), array('item 5'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 5'));
- $this->click($base.'button5');
+ $this->click("{$base}button5");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels($base.'list1'), array('item 2', 'item 5'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 5'));
- $this->click($base.'button2');
+ $this->click("{$base}button2");
$this->pause(800);
- $this->assertNotSomethingSelected($base."list1");
+ $this->assertNotSomethingSelected("{$base}list1");
- $this->click($base.'button6');
+ $this->click("{$base}button6");
$this->pause(800);
- $this->click($base."button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels($base.'list1'), array('item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 3', 'item 4'));
- $this->select($base."list1", "item 1");
+ $this->select("{$base}list1", "item 1");
$this->pause(800);
- $this->assertText($base.'label1', 'Selection: value 1');
+ $this->assertText("{$base}label1", 'Selection: value 1');
- $this->addSelection($base."list1", "item 4");
+ $this->addSelection("{$base}list1", "item 4");
$this->pause(800);
- $this->assertText($base.'label1', 'Selection: value 1, value 4');
+ $this->assertText("{$base}label1", 'Selection: value 1, value 4');
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveListBoxTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveListBoxTestCase.php
index d45cb42c..8818f78e 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveListBoxTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveListBoxTestCase.php
@@ -1,46 +1,47 @@
<?php
-class ActiveListBoxTestCase extends PradoGenericSeleniumTest
+class ActiveListBoxTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveListBoxTest");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveListBoxTest");
$this->assertTextPresent('Active List Box Functional Test');
- $this->assertText("label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels('list1'), array('item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 3', 'item 4'));
- $this->click('button3');
+ $this->click("{$base}button3");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels('list1'), array('item 1'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 1'));
- $this->click('button4');
+ $this->click("{$base}button4");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels('list1'), array('item 5'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 5'));
- $this->click('button5');
+ $this->click("{$base}button5");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels('list1'), array('item 2', 'item 5'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 5'));
- $this->click('button2');
+ $this->click("{$base}button2");
$this->pause(800);
- $this->assertNotSomethingSelected("list1");
+ $this->assertNotSomethingSelected("{$base}list1");
- $this->click('button6');
+ $this->click("{$base}button6");
$this->pause(800);
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertEquals($this->getSelectedLabels('list1'), array('item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectedLabels("{$base}list1"), array('item 2', 'item 3', 'item 4'));
- $this->select("list1", "item 1");
+ $this->select("{$base}list1", "item 1");
$this->pause(800);
- $this->assertText('label1', 'Selection: value 1');
+ $this->assertText("{$base}label1", 'Selection: value 1');
- $this->addSelection("list1", "item 4");
+ $this->addSelection("{$base}list1", "item 4");
$this->pause(800);
- $this->assertText('label1', 'Selection: value 1, value 4');
+ $this->assertText("{$base}label1", 'Selection: value 1, value 4');
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/active-controls/tests/ActivePanelTestCase.php b/tests/FunctionalTests/active-controls/tests/ActivePanelTestCase.php
index 9b069a14..528b542c 100755
--- a/tests/FunctionalTests/active-controls/tests/ActivePanelTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActivePanelTestCase.php
@@ -1,11 +1,12 @@
<?php
-class ActivePanelTestCase extends PradoGenericSeleniumTest
+class ActivePanelTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActivePanelTest");
- $this->verifyTextPresent("Active Panel replacement tests");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActivePanelTest");
+ $this->assertTextPresent("Active Panel replacement tests");
$this->assertTextNotPresent('Something lalala');
$this->click("div1");
$this->pause(800);
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonListTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonListTestCase.php
index b0942ffa..597567a0 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonListTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonListTestCase.php
@@ -1,45 +1,47 @@
<?php
-class ActiveRadioButtonListTestCase extends PradoGenericSeleniumTest
+class ActiveRadioButtonListTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveRadioButtonListTest");
- $this->verifyTextPresent("TActiveRadioButtonList Test Case");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveRadioButtonListTest");
+ $this->assertTextPresent("TActiveRadioButtonList Test Case");
- $this->assertText("label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->click("button3");
+ $this->click("{$base}button3");
$this->pause(800);
$this->assertCheckBoxes(array(0));
- $this->click("button2");
+ $this->click("{$base}button2");
$this->pause(800);
$this->assertCheckBoxes(array());
- $this->click("button4");
+ $this->click("{$base}button4");
$this->pause(800);
$this->assertCheckBoxes(array(4));
- $this->click("list1_c2");
+ $this->click("{$base}list1_c2");
$this->pause(800);
- $this->assertText("label1", "Selection: value 3");
+ $this->assertText("{$base}label1", "Selection: value 3");
- $this->click("list1_c3");
+ $this->click("{$base}list1_c3");
$this->pause(800);
- $this->assertText("label1", "Selection: value 4");
+ $this->assertText("{$base}label1", "Selection: value 4");
}
function assertCheckBoxes($checks, $total = 5)
{
+ $base='ctl0_Content_';
for($i = 0; $i < $total; $i++)
{
if(in_array($i, $checks))
- $this->assertChecked("list1_c{$i}");
+ $this->assertChecked("{$base}list1_c{$i}");
else
- $this->assertNotChecked("list1_c{$i}");
+ $this->assertNotChecked("{$base}list1_c{$i}");
}
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonTestCase.php b/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonTestCase.php
index fceb2e21..04837ef4 100755
--- a/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ActiveRadioButtonTestCase.php
@@ -1,52 +1,53 @@
<?php
-class ActiveRadioButtonTestCase extends PradoGenericSeleniumTest
+class ActiveRadioButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveRadioButtonTest");
- $this->verifyTextPresent("Active Radio Button Test");
- $this->assertText('label1', 'Label 1');
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveRadioButtonTest");
+ $this->assertTextPresent("Active Radio Button Test");
+ $this->assertText("{$base}label1", 'Label 1');
- $this->assertNotChecked('radio1');
- $this->assertNotChecked('radio2');
- $this->assertNotChecked('radio3');
+ $this->assertNotChecked("{$base}radio1");
+ $this->assertNotChecked("{$base}radio2");
+ $this->assertNotChecked("{$base}radio3");
- $this->assertText('radio1_label', 'Radio Button 1');
- $this->assertText('radio2_label', 'Radio Button 2');
- $this->assertText('radio3_label', 'Radio Button 3');
+ $this->assertText("{$base}radio1_label", 'Radio Button 1');
+ $this->assertText("{$base}radio2_label", 'Radio Button 2');
+ $this->assertText("{$base}radio3_label", 'Radio Button 3');
- $this->click('change_text1');
+ $this->click("{$base}change_text1");
$this->pause(800);
- $this->assertText('radio1_label', 'Hello Radio Button 1');
- $this->assertText('radio2_label', 'Radio Button 2');
- $this->assertText('radio3_label', 'Radio Button 3');
+ $this->assertText("{$base}radio1_label", 'Hello Radio Button 1');
+ $this->assertText("{$base}radio2_label", 'Radio Button 2');
+ $this->assertText("{$base}radio3_label", 'Radio Button 3');
- $this->click('change_text2');
+ $this->click("{$base}change_text2");
$this->pause(800);
- $this->assertText('radio1_label', 'Hello Radio Button 1');
- $this->assertText('radio2_label', 'Radio Button 2 World');
- $this->assertText('radio3_label', 'Radio Button 3');
+ $this->assertText("{$base}radio1_label", 'Hello Radio Button 1');
+ $this->assertText("{$base}radio2_label", 'Radio Button 2 World');
+ $this->assertText("{$base}radio3_label", 'Radio Button 3');
- $this->click('change_radio1');
+ $this->click("{$base}change_radio1");
$this->pause(800);
- $this->assertChecked('radio1');
- $this->assertNotChecked('radio2');
- $this->assertNotChecked('radio3');
+ $this->assertChecked("{$base}radio1");
+ $this->assertNotChecked("{$base}radio2");
+ $this->assertNotChecked("{$base}radio3");
- $this->click('change_radio2');
+ $this->click("{$base}change_radio2");
$this->pause(800);
- $this->assertNotChecked('radio1');
- $this->assertChecked('radio2');
- $this->assertNotChecked('radio3');
+ $this->assertNotChecked("{$base}radio1");
+ $this->assertChecked("{$base}radio2");
+ $this->assertNotChecked("{$base}radio3");
- $this->click('radio3');
+ $this->click("{$base}radio3");
$this->pause(800);
- $this->assertNotChecked('radio1');
- $this->assertChecked('radio2');
- $this->assertChecked('radio3');
- $this->assertText('label1', 'Label 1:Radio Button 3 Checked');
+ $this->assertNotChecked("{$base}radio1");
+ $this->assertChecked("{$base}radio2");
+ $this->assertChecked("{$base}radio3");
+ $this->assertText("{$base}label1", 'Label 1:Radio Button 3 Checked');
}
diff --git a/tests/FunctionalTests/active-controls/tests/AutoCompleteTestCase.php b/tests/FunctionalTests/active-controls/tests/AutoCompleteTestCase.php
index 94cae5f2..f6dfc22b 100755
--- a/tests/FunctionalTests/active-controls/tests/AutoCompleteTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/AutoCompleteTestCase.php
@@ -1,42 +1,43 @@
<?php
-class AutoCompleteTestCase extends PradoGenericSeleniumTest
+class AutoCompleteTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=AutoCompleteTest");
- $this->verifyTextPresent("TAutoComplete Test");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=AutoCompleteTest");
+ $this->assertTextPresent("TAutoComplete Test");
- $this->assertText("label1", "Label 1");
+ $this->assertText("{$base}label1", "Label 1");
- $this->type("textbox3", 'a');
- $this->runScript('Prado.Registry[\'textbox3\'].onKeyPress({})');
+ $this->click("{$base}textbox3");
+ $this->keys('a');
$this->pause(500);
- $this->verifyTextPresent('Andorra');
- $this->assertText("label1", "suggestion for a");
+ $this->assertTextPresent('Andorra');
+ $this->assertText("{$base}label1", "suggestion for a");
- $this->type("textbox3", 'au');
- $this->runScript('Prado.Registry[\'textbox3\'].onKeyPress({})');
+ $this->keys('u');
$this->pause(500);
- $this->verifyTextPresent('Australia');
- $this->assertText("label1", "suggestion for au");
+ $this->assertTextPresent('Australia');
+ $this->assertText("{$base}label1", "suggestion for au");
- $this->click("css=#textbox3_result ul li");
+ $this->click("css=#{$base}textbox3_result ul li");
$this->pause(500);
- $this->assertText("label1", "Label 1: Austria");
+ $this->assertText("{$base}label1", "Label 1: Austria");
- $this->type("textbox2", "cu");
- $this->runScript('Prado.Registry[\'textbox2\'].onKeyPress({})');
+
+ $this->click("{$base}textbox2");
+ $this->keys('cu');
$this->pause(500);
- $this->click('css=#textbox2_result ul li');
+ $this->click("css=#{$base}textbox2_result ul li");
$this->pause(500);
- $this->assertText("label1", "Label 1: Cuba");
+ $this->assertText("{$base}label1", "Label 1: Cuba");
- $this->type("textbox2", "Cuba,me");
- $this->runScript('Prado.Registry[\'textbox2\'].onKeyPress({})');
+ $this->keys(PHPUnit_Extensions_Selenium2TestCase_Keys::END);
+ $this->keys(',me');
$this->pause(500);
- $this->click('css=#textbox2_result ul li');
+ $this->click("css=#{$base}textbox2_result ul li");
$this->pause(500);
- $this->assertText("label1", "Label 1: Cuba,Mexico");
+ $this->assertText("{$base}label1", "Label 1: Cuba,Mexico");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/CalculatorTestCase.php b/tests/FunctionalTests/active-controls/tests/CalculatorTestCase.php
index 48960d39..28cbb870 100755
--- a/tests/FunctionalTests/active-controls/tests/CalculatorTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/CalculatorTestCase.php
@@ -1,23 +1,24 @@
<?php
-class CalculatorTestCase extends PradoGenericSeleniumTest
+class CalculatorTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=Calculator");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=Calculator");
$this->assertTextPresent("Callback Enabled Calculator");
- $this->assertNotVisible("summary");
-
- $this->click("sum");
- $this->assertVisible("summary");
-
- $this->type("a", "2");
- $this->type("b", "5");
-
- $this->click("sum");
+ $this->assertNotVisible("{$base}summary");
+
+ $this->click("{$base}sum");
+ $this->assertVisible("{$base}summary");
+
+ $this->type("{$base}a", "2");
+ $this->type("{$base}b", "5");
+
+ $this->click("{$base}sum");
$this->pause(500);
- $this->assertNotVisible("summary");
- $this->assertValue("c", "7");
+ $this->assertNotVisible("{$base}summary");
+ $this->assertValue("{$base}c", "7");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/CallbackAdapterTestCase.php b/tests/FunctionalTests/active-controls/tests/CallbackAdapterTestCase.php
index c495935a..75de3419 100755
--- a/tests/FunctionalTests/active-controls/tests/CallbackAdapterTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/CallbackAdapterTestCase.php
@@ -1,29 +1,29 @@
<?php
-class CallbackAdapterTestCase extends PradoGenericSeleniumTest
+class CallbackAdapterTestCase extends PradoGenericSelenium2Test
{
function test()
{
-
- $this->open("active-controls/index.php?page=ControlAdapterTest");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ControlAdapterTest");
$this->assertTextPresent('Control Adapter - State Tracking Tests');
- $this->click('button2');
+ $this->click("{$base}button2");
$this->assertAlert('ok');
- $this->click('test6');
+ $this->click("{$base}test6");
$this->pause(800);
- $this->click('test7');
+ $this->click("{$base}test7");
$this->pause(800);
- $this->click('test8');
+ $this->click("{$base}test8");
$this->pause(800);
- $this->click('test9');
+ $this->click("{$base}test9");
$this->pause(800);
- $this->click('button1');
+ $this->click("{$base}button1");
$this->assertAlert('haha!');
- $this->click('button2');
+ $this->click("{$base}button2");
$this->assertAlert('ok');
$this->assertAlert('baz!');
@@ -31,10 +31,10 @@ class CallbackAdapterTestCase extends PradoGenericSeleniumTest
/*
function testIE()
{
- $this->open("active-controls/index.php?page=ControlAdapterTest");
+ $this->url("active-controls/index.php?page=ControlAdapterTest");
$this->assertTextPresent('Control Adapter - State Tracking Tests');
- $this->click('button2');
+ $this->click("{$base}button2");
$this->assertAlert('ok');
$this->click('test6');
@@ -46,11 +46,11 @@ class CallbackAdapterTestCase extends PradoGenericSeleniumTest
$this->click('test9');
$this->pause(800);
- $this->click('button1');
+ $this->click("{$base}button1");
$this->assertAlert('haha!');
//IE alerts in diffrent order
- $this->click('button2');
+ $this->click("{$base}button2");
$this->assertAlert('baz!');
$this->assertAlert('ok');
}
diff --git a/tests/FunctionalTests/active-controls/tests/CallbackOptionsTestCase.php b/tests/FunctionalTests/active-controls/tests/CallbackOptionsTestCase.php
index d1f48cf3..634f4015 100755
--- a/tests/FunctionalTests/active-controls/tests/CallbackOptionsTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/CallbackOptionsTestCase.php
@@ -1,29 +1,30 @@
<?php
-class CallbackOptionsTestCase extends PradoGenericSeleniumTest
+class CallbackOptionsTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=CallbackOptionsTest");
- $this->verifyTextPresent("TCallbackOptions Test");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=CallbackOptionsTest");
+ $this->assertTextPresent("TCallbackOptions Test");
$this->assertText("label1", "Label 1");
$this->assertText("label2", "Label 2");
$this->assertText("label3", "Label 3");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
$this->assertText("label1", "Button 1 has returned");
$this->assertText("label2", "Label 2");
$this->assertText("label3", "Label 3");
- $this->click("button2");
+ $this->click("{$base}button2");
$this->pause(800);
$this->assertText("label1", "Button 1 has returned");
$this->assertText("label2", "Button 2 has returned");
$this->assertText("label3", "Label 3");
- $this->click("button3");
+ $this->click("{$base}button3");
$this->pause(800);
$this->assertText("label1", "Button 1 has returned");
$this->assertText("label2", "Button 2 has returned");
diff --git a/tests/FunctionalTests/active-controls/tests/CustomTemplateTestCase.php b/tests/FunctionalTests/active-controls/tests/CustomTemplateTestCase.php
index e72d021e..d17cf90f 100755
--- a/tests/FunctionalTests/active-controls/tests/CustomTemplateTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/CustomTemplateTestCase.php
@@ -1,20 +1,21 @@
<?php
-class CustomTemplateTestCase extends PradoGenericSeleniumTest
+class CustomTemplateTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('active-controls/index.php?page=CustomTemplateControlTest');
+ $base='ctl0_Content_';
+ $this->url('active-controls/index.php?page=CustomTemplateControlTest');
$this->assertTextPresent('Add Dynamic Custom TTemplateControl Test');
- $this->assertText('label1', 'Label 1');
+ $this->assertText("{$base}label1", 'Label 1');
- $this->type('foo', 'Foo Bar!');
- $this->click('button2');
+ $this->type("{$base}foo", 'Foo Bar!');
+ $this->click("{$base}button2");
$this->pause(800);
- $this->assertVisible('ctl0_ThePanel');
- $this->assertTextPresent('Client ID: ctl0_ThePanel');
+ $this->assertVisible("{$base}ctl0_ThePanel");
+ $this->assertTextPresent("Client ID: {$base}ctl0_ThePanel");
- $this->assertText('label1', 'Button 1 was clicked Foo Bar! using callback!... and this is the textbox text: Foo Bar!');
+ $this->assertText("{$base}label1", 'Button 1 was clicked Foo Bar! using callback!... and this is the textbox text: Foo Bar!');
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php b/tests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php
index 841de5aa..2b1eec75 100755
--- a/tests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/DelayedCallbackTestCase.php
@@ -1,20 +1,21 @@
<?php
-class DelayedCallbackTestCase extends PradoGenericSeleniumTest
+class DelayedCallbackTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=DelayedCallback");
- $this->verifyTextPresent("Delayed Callback Test");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=DelayedCallback");
+ $this->assertTextPresent("Delayed Callback Test");
- $this->assertText("status", "");
- $this->click("button1");
- $this->click("button2");
+ $this->assertText("{$base}status", "");
+ $this->click("{$base}button1");
+ $this->click("{$base}button2");
$this->pause("5000");
- $this->assertText("status", "Callback 1 returned after 4s");
+ $this->assertText("{$base}status", "Callback 1 returned after 4s");
$this->pause("3000");
- $this->assertText("status", "Callback 2 delayed 2s");
+ $this->assertText("{$base}status", "Callback 2 delayed 2s");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/EventTriggerTestCase.php b/tests/FunctionalTests/active-controls/tests/EventTriggerTestCase.php
index 30678786..7c73a8e8 100755
--- a/tests/FunctionalTests/active-controls/tests/EventTriggerTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/EventTriggerTestCase.php
@@ -1,20 +1,21 @@
<?php
-class EventTriggerTestCase extends PradoGenericSeleniumTest
+class EventTriggerTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=EventTriggeredCallback");
- $this->verifyTextPresent("Event Triggered Callback Test");
+ $base = "ctl0_Content_";
+ $this->url("active-controls/index.php?page=EventTriggeredCallback");
+ $this->assertTextPresent("Event Triggered Callback Test");
- $this->assertText('label1', 'Label 1');
+ $this->assertText("{$base}label1", 'Label 1');
- $this->click('button1');
+ $this->click("button1");
$this->pause(800);
- $this->assertText('label1', 'button 1 clicked');
+ $this->assertText("{$base}label1", 'button 1 clicked');
- $this->type('text1', 'test');
+ $this->type("{$base}text1", 'test');
$this->pause(800);
- $this->assertText('label1', 'text 1 focused');
+ $this->assertText("{$base}label1", 'text 1 focused');
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/NestedActiveControlsTestCase.php b/tests/FunctionalTests/active-controls/tests/NestedActiveControlsTestCase.php
index e2ceb33e..1b686d0a 100755
--- a/tests/FunctionalTests/active-controls/tests/NestedActiveControlsTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/NestedActiveControlsTestCase.php
@@ -1,24 +1,25 @@
<?php
-class NestedActiveControlsTestCase extends PradoGenericSeleniumTest
+class NestedActiveControlsTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=NestedActiveControls");
- $this->verifyTextPresent("Nested Active Controls Test");
- $this->assertText("label1", "Label 1");
- $this->assertText("label2", "Label 2");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=NestedActiveControls");
+ $this->assertTextPresent("Nested Active Controls Test");
+ $this->assertText("{$base}label1", "Label 1");
+ $this->assertText("{$base}label2", "Label 2");
$this->assertTextNotPresent("Label 3");
$this->click("div1");
$this->pause(800);
$this->assertTextPresent("Something lalala");
- $this->assertText("label3", "Label 3");
+ $this->assertText("{$base}label3", "Label 3");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->assertText("label1", "Label 1: Button 1 Clicked");
- $this->assertText("label2", "Label 2: Button 1 Clicked");
- $this->assertText("label3", "Label 3: Button 1 Clicked");
+ $this->assertText("{$base}label1", "Label 1: Button 1 Clicked");
+ $this->assertText("{$base}label2", "Label 2: Button 1 Clicked");
+ $this->assertText("{$base}label3", "Label 3: Button 1 Clicked");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/PopulateListTestCase.php b/tests/FunctionalTests/active-controls/tests/PopulateListTestCase.php
index adb5a3a5..92944429 100755
--- a/tests/FunctionalTests/active-controls/tests/PopulateListTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/PopulateListTestCase.php
@@ -1,23 +1,24 @@
<?php
-class PopulateListTestCase extends PradoGenericSeleniumTest
+class PopulateListTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=PopulateActiveList");
- $this->verifyTextPresent("Populate active list controls");
- $this->assertText("label1", "");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=PopulateActiveList");
+ $this->assertTextPresent("Populate active list controls");
+ $this->assertText("{$base}label1", "");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(800);
- $this->select("list1", "World");
+ $this->select("{$base}list1", "World");
$this->pause(800);
- $this->assertText("label1", "list1: World");
+ $this->assertText("{$base}label1", "list1: World");
- $this->click("button2");
+ $this->click("{$base}button2");
$this->pause(800);
- $this->select("list2", "Prado");
+ $this->select("{$base}list2", "Prado");
$this->pause(800);
- $this->assertText("label1", "list2: Prado");
+ $this->assertText("{$base}label1", "list2: Prado");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/PostLoadingTestCase.php b/tests/FunctionalTests/active-controls/tests/PostLoadingTestCase.php
index 21a5128d..99f21585 100755
--- a/tests/FunctionalTests/active-controls/tests/PostLoadingTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/PostLoadingTestCase.php
@@ -1,18 +1,19 @@
<?php
-class PostLoadingTestCase extends PradoGenericSeleniumTest
+class PostLoadingTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('active-controls/index.php?page=PostLoadingTest');
+ $base="ctl0_Content_";
+ $this->url('active-controls/index.php?page=PostLoadingTest');
$this->assertTextPresent('PostLoading Test');
$this->assertTextNotPresent('Hello World');
$this->click('div1');
$this->pause(800);
- $this->type('MyTextBox', 'Hello World');
- $this->click('MyButton');
+ $this->type("{$base}MyTextBox", 'Hello World');
+ $this->click("{$base}MyButton");
$this->pause(800);
$this->assertTextPresent('Result is Hello World');
diff --git a/tests/FunctionalTests/active-controls/tests/ReplaceContentTestCase.php b/tests/FunctionalTests/active-controls/tests/ReplaceContentTestCase.php
index fd273ae7..8f38ac17 100755
--- a/tests/FunctionalTests/active-controls/tests/ReplaceContentTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ReplaceContentTestCase.php
@@ -1,90 +1,90 @@
<?php
-class ReplaceContentTestCase extends PradoGenericSeleniumTest
+class ReplaceContentTestCase extends PradoGenericSelenium2Test
{
function test()
{
-
- $this->open('active-controls/index.php?page=ReplaceContentTest');
+ $base='ctl0_Content_';
+ $this->url('active-controls/index.php?page=ReplaceContentTest');
$this->assertTextPresent('Callback Replace Content Test');
- $this->assertText('subpanel', 'Sub Panel');
- $this->assertText('panel1', 'Main Panel Sub Panel');
+ $this->assertText("{$base}subpanel", 'Sub Panel');
+ $this->assertText("{$base}panel1", "Main Panel\nSub Panel");
- $this->type('content', 'something');
+ $this->type("{$base}content", 'something');
- $this->click('btn_append');
+ $this->click("{$base}btn_append");
$this->pause(800);
- $this->assertText('subpanel', 'Sub Panel something');
- $this->assertText('panel1', 'Main Panel Sub Panel something');
+ $this->assertText("{$base}subpanel", 'Sub Panel something');
+ $this->assertText("{$base}panel1", "Main Panel\nSub Panel something");
- $this->type('content', 'more');
- $this->click('btn_prepend');
+ $this->type("{$base}content", 'more');
+ $this->click("{$base}btn_prepend");
$this->pause(800);
- $this->assertText('subpanel', 'more Sub Panel something');
- $this->assertText('panel1', 'Main Panel more Sub Panel something');
+ $this->assertText("{$base}subpanel", 'more Sub Panel something');
+ $this->assertText("{$base}panel1", "Main Panel\nmore Sub Panel something");
- $this->type('content', 'prado');
- $this->click('btn_before');
+ $this->type("{$base}content", 'prado');
+ $this->click("{$base}btn_before");
$this->pause(800);
- $this->assertText('subpanel', 'more Sub Panel something');
- $this->assertText('panel1', 'Main Panel pradomore Sub Panel something');
+ $this->assertText("{$base}subpanel", 'more Sub Panel something');
+ $this->assertText("{$base}panel1", "Main Panel prado\nmore Sub Panel something");
- $this->type('content', ' php ');
- $this->click('btn_after');
+ $this->type("{$base}content", ' php ');
+ $this->click("{$base}btn_after");
$this->pause(800);
- $this->type('content', 'mauahahaha');
- $this->click('btn_replace');
+ $this->type("{$base}content", 'mauahahaha');
+ $this->click("{$base}btn_replace");
$this->pause(1000);
- $this->assertText('panel1', 'Main Panel pradomauahahahaphp');
+ $this->assertText("{$base}panel1", 'Main Panel pradomauahahaha php');
}
/*
function testIE()
{
- $this->open('active-controls/index.php?page=ReplaceContentTest');
+ $this->url('active-controls/index.php?page=ReplaceContentTest');
$this->assertTextPresent('Callback Replace Content Test');
- $this->assertText('subpanel', 'Sub Panel');
- $this->assertText('panel1', 'regexp:Main Panel\s*Sub Panel');
+ $this->assertText("{$base}subpanel", 'Sub Panel');
+ $this->assertText("{$base}panel1", 'regexp:Main Panel\s*Sub Panel');
- $this->type('content', 'something');
+ $this->type("{$base}content", 'something');
$this->click('btn_append');
$this->pause(800);
- $this->assertText('subpanel', 'Sub Panel something');
- $this->assertText('panel1', 'regexp:Main Panel\s*Sub Panel\s*something');
+ $this->assertText("{$base}subpanel", 'Sub Panel something');
+ $this->assertText("{$base}panel1", 'regexp:Main Panel\s*Sub Panel\s*something');
- $this->type('content', 'more');
+ $this->type("{$base}content", 'more');
$this->click('btn_prepend');
$this->pause(800);
- $this->assertText('subpanel', 'regexp:more\s*Sub Panel\s*something');
- $this->assertText('panel1', 'regexp:Main Panel\s*moreSub Panel\s*something');
+ $this->assertText("{$base}subpanel", 'regexp:more\s*Sub Panel\s*something');
+ $this->assertText("{$base}panel1", 'regexp:Main Panel\s*moreSub Panel\s*something');
- $this->type('content', 'prado');
+ $this->type("{$base}content", 'prado');
$this->click('btn_before');
$this->pause(800);
- $this->assertText('subpanel', 'regexp:more\s*Sub Panel\s*something');
- $this->assertText('panel1', 'regexp:Main Panel\s*prado\s*more\s*Sub Panel\s*something');
+ $this->assertText("{$base}subpanel", 'regexp:more\s*Sub Panel\s*something');
+ $this->assertText("{$base}panel1", 'regexp:Main Panel\s*prado\s*more\s*Sub Panel\s*something');
- $this->type('content', ' php ');
+ $this->type("{$base}content", ' php ');
$this->click('btn_after');
$this->pause(800);
- $this->type('content', 'mauahahaha');
+ $this->type("{$base}content", 'mauahahaha');
$this->click('btn_replace');
$this->pause(1000);
- $this->assertText('panel1', 'Main Panel pradomauahahahaphp');
+ $this->assertText("{$base}panel1", 'Main Panel pradomauahahahaphp');
}
*/
}
diff --git a/tests/FunctionalTests/active-controls/tests/TextBoxCallbackTestCase.php b/tests/FunctionalTests/active-controls/tests/TextBoxCallbackTestCase.php
index 14d575fe..d6728298 100755
--- a/tests/FunctionalTests/active-controls/tests/TextBoxCallbackTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/TextBoxCallbackTestCase.php
@@ -1,15 +1,16 @@
<?php
-class TextBoxCallbackTestCase extends PradoGenericSeleniumTest
+class TextBoxCallbackTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ActiveTextBoxCallback");
- $this->verifyTextPresent("ActiveTextBox Callback Test");
- $this->assertText("label1", "Label 1");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ActiveTextBoxCallback");
+ $this->assertTextPresent("ActiveTextBox Callback Test");
+ $this->assertText("{$base}label1", "Label 1");
- $this->type("textbox1", "hello!");
+ $this->type("{$base}textbox1", "hello!");
$this->pause(800);
- $this->assertText("label1", "Label 1: hello!");
+ $this->assertText("{$base}label1", "Label 1: hello!");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/TextBoxGroupValidationTestCase.php b/tests/FunctionalTests/active-controls/tests/TextBoxGroupValidationTestCase.php
index ffc1ac72..1a5e1b2f 100755
--- a/tests/FunctionalTests/active-controls/tests/TextBoxGroupValidationTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/TextBoxGroupValidationTestCase.php
@@ -1,22 +1,23 @@
<?php
-class TextBoxGroupValidationTestCase extends PradoGenericSeleniumTest
+class TextBoxGroupValidationTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=TextBoxValidationCallback");
+ $base="ctl0_Content_";
+ $this->url("active-controls/index.php?page=TextBoxValidationCallback");
$this->assertTextPresent('TextBox AutoPostBack With Group Validation');
- $this->assertNotVisible('validator1');
+ $this->assertNotVisible("{$base}validator1");
- $this->type('ZipCode', 'test');
- $this->assertVisible('validator1');
+ $this->type("{$base}ZipCode", 'test');
+ $this->assertVisible("{$base}validator1");
- $this->type('Address', 'Sydney');
- $this->type('ZipCode', '2000');
+ $this->type("{$base}Address", 'Sydney');
+ $this->type("{$base}ZipCode", '2000');
- $this->assertNotVisible('validator1');
+ $this->assertNotVisible("{$base}validator1");
$this->pause(800);
- $this->assertValue('City', 'City: Sydney Zip: 2000');
+ $this->assertValue("{$base}City", 'City: Sydney Zip: 2000');
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/TimeTriggeredCallbackTestCase.php b/tests/FunctionalTests/active-controls/tests/TimeTriggeredCallbackTestCase.php
index de0ecad8..ee0cde18 100755
--- a/tests/FunctionalTests/active-controls/tests/TimeTriggeredCallbackTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/TimeTriggeredCallbackTestCase.php
@@ -1,19 +1,20 @@
<?php
-class TimeTriggeredCallbackTestCase extends PradoGenericSeleniumTest
+class TimeTriggeredCallbackTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=TimeTriggeredCallbackTest");
- $this->verifyTextPresent("TimeTriggeredCallback + ViewState Tests");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=TimeTriggeredCallbackTest");
+ $this->assertTextPresent("TimeTriggeredCallback + ViewState Tests");
- $this->assertText("label1", "ViewState Counter :");
+ $this->assertText("{$base}label1", "ViewState Counter :");
- $this->click("button1");
+ $this->click("{$base}button1");
$this->pause(8000);
- $this->assertText("label1", "ViewState Counter : 1 2 3 4 5 6 7 8 9 10");
+ $this->assertText("{$base}label1", "ViewState Counter : 1 2 3 4 5 6 7 8 9 10");
}
}
diff --git a/tests/FunctionalTests/active-controls/tests/ValueTriggerCallbackTestCase.php b/tests/FunctionalTests/active-controls/tests/ValueTriggerCallbackTestCase.php
index 5113cc92..e89a65e4 100755
--- a/tests/FunctionalTests/active-controls/tests/ValueTriggerCallbackTestCase.php
+++ b/tests/FunctionalTests/active-controls/tests/ValueTriggerCallbackTestCase.php
@@ -1,20 +1,21 @@
<?php
-class ValueTriggerTestCase extends PradoGenericSeleniumTest
+class ValueTriggerTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("active-controls/index.php?page=ValueTriggerCallbackTest");
- $this->verifyTextPresent("Value Trigger Callback Test");
+ $base='ctl0_Content_';
+ $this->url("active-controls/index.php?page=ValueTriggerCallbackTest");
+ $this->assertTextPresent("Value Trigger Callback Test");
- $this->assertText('label1', 'Label 1');
+ $this->assertText("{$base}label1", 'Label 1');
- $this->type('text1', 'test');
+ $this->type("{$base}text1", 'test');
$this->pause(2000);
- $this->assertText('label1', 'Old = : New Value = test');
+ $this->assertText("{$base}label1", 'Old = : New Value = test');
- $this->type('text1', 'more');
+ $this->type("{$base}text1", 'more');
$this->pause(3000);
- $this->assertText('label1', 'Old = test : New Value = more');
+ $this->assertText("{$base}label1", 'Old = test : New Value = more');
}
}
diff --git a/tests/FunctionalTests/active-controlstests/ActiveRatingListTestCase.php b/tests/FunctionalTests/active-controlstests/ActiveRatingListTestCase.php
index ef82eaa3..d4aa6788 100755
--- a/tests/FunctionalTests/active-controlstests/ActiveRatingListTestCase.php
+++ b/tests/FunctionalTests/active-controlstests/ActiveRatingListTestCase.php
@@ -1,240 +1,248 @@
<?php
/**
* ActiveRatingListTestCase.php
- *
+ *
* @author Bradley Booms <Bradley.Booms@nsighttel.com>
* @version Creation Date: Oct 22, 2008
*/
/**
* ActiveRatingListTestCase.php class
- *
- *
- *
+ *
+ *
+ *
* Properties
* -
- *
+ *
* @author Bradley Booms <Bradley.Booms@nsighttel.com>
* @version Modified Date: Oct 22, 2008
- *
+ *
* Modifications:
*/
-class ActiveRatingListTestCase extends PradoGenericSeleniumTest
+class ActiveRatingListTestCase extends PradoGenericSelenium2Test
{
function testCheckBoxes()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListCheckBoxesTest");
- $this->verifyTextPresent("TActiveRatingList Check Boxes Test Case");
- $this->assertCheckBoxes("RatingList", array(2), 6);
-
+ $this->url("active-controls/index.php?page=ActiveRatingListCheckBoxesTest");
+ $this->assertTextPresent("TActiveRatingList Check Boxes Test Case");
+ $this->assertCheckBoxes("{$base}RatingList", array(2), 6);
+
// Change the list and make sure the radio buttons get updated properly.
- $this->clickTD("RatingList_c4");
+ $this->clickTD("{$base}RatingList_c4");
$this->pause(800);
- $this->assertCheckBoxes("RatingList", array(4), 6);
-
- $this->clickTD("RatingList_c2");
+ $this->assertCheckBoxes("{$base}RatingList", array(4), 6);
+
+ $this->clickTD("{$base}RatingList_c2");
$this->pause(800);
- $this->assertCheckBoxes("RatingList", array(2), 6);
+ $this->assertCheckBoxes("{$base}RatingList", array(2), 6);
}
function testRating()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListRatingTest");
- $this->verifyTextPresent("TActiveRatingList Rating Test Case");
-
+ $this->url("active-controls/index.php?page=ActiveRatingListRatingTest");
+ $this->assertTextPresent("TActiveRatingList Rating Test Case");
+
// Check the list, make sure it starts out with 5 stars.
- $this->assertText("Status", "Rating: 5");
-
+ $this->assertText("{$base}Status", "Rating: 5");
+
// Click on 1 star and make sure the Rating property updates.
- $this->clickTD("RatingList_c0");
+ $this->clickTD("{$base}RatingList_c0");
$this->pause(800);
- $this->assertText("Status", "Rating: 1");
-
+ $this->assertText("{$base}Status", "Rating: 1");
+
// Then set Rating to three on the server side and make sure it's correct.
- $this->click("SetRating");
+ $this->click("{$base}SetRating");
$this->pause(800);
- $this->assertText("Status", "Rating: 3");
+ $this->assertText("{$base}Status", "Rating: 3");
}
function testSelectedIndex()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListSelectedIndexTest");
- $this->verifyTextPresent("TActiveRatingList SelectedIndex Test Case");
- $this->assertText("Status", " SelectedIndex: 1");
-
+ $this->url("active-controls/index.php?page=ActiveRatingListSelectedIndexTest");
+ $this->assertTextPresent("TActiveRatingList SelectedIndex Test Case");
+ $this->assertText("{$base}Status", "SelectedIndex: 1");
+
// Click on 5 stars and make sure the SelectedIndex property updates.
- $this->clickTD("RatingList_c4");
+ $this->clickTD("{$base}RatingList_c4");
$this->pause(800);
- $this->assertText("Status", " SelectedIndex: 4");
-
+ $this->assertText("{$base}Status", "SelectedIndex: 4");
+
// Then set SelectedIndex to 5 on the server side and make sure it's correct.
- $this->click("SetSelectedIndex");
+ $this->click("{$base}SetSelectedIndex");
$this->pause(800);
- $this->assertText("Status", " SelectedIndex: 5");
+ $this->assertText("{$base}Status", "SelectedIndex: 5");
}
function testAutoPostBack()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListAutoPostBackTest");
- $this->verifyTextPresent("TActiveRatingList AutoPostBack Test Case");
- $this->assertText("Status", "AutoPostback=false");
-
+ $this->url("active-controls/index.php?page=ActiveRatingListAutoPostBackTest");
+ $this->assertTextPresent("TActiveRatingList AutoPostBack Test Case");
+ $this->assertText("{$base}Status", "AutoPostback=false");
+
// Make sure that it doesn't auto post when clicked.
- $this->clickTD("RatingList_c3");
+ $this->clickTD("{$base}RatingList_c3");
$this->pause(800);
- $this->assertText("Status", "AutoPostback=false");
-
+ $this->assertText("{$base}Status", "AutoPostback=false");
+
// Then submit with an active button and make sure it updates.
- $this->click("Submit");
+ $this->click("{$base}Submit");
$this->pause(800);
- $this->assertText("Status", "4 : Good");
+ $this->assertText("{$base}Status", "4 : Good");
}
function testAllowInput()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListAllowInputTest");
- $this->verifyTextPresent("TActiveRatingList AllowInput Test Case");
- $this->assertText("Status", "AllowInput=false");
- $this->assertCheckBoxes("RatingList", array(3), 6);
+ $this->url("active-controls/index.php?page=ActiveRatingListAllowInputTest");
+ $this->assertTextPresent("TActiveRatingList AllowInput Test Case");
+ $this->assertText("{$base}Status", "AllowInput=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(3), 6);
// Make sure that clicking doesn't change anything.
- $this->clickTD("RatingList_c5");
+ $this->clickTD("{$base}RatingList_c5");
$this->pause(800);
- $this->assertText("Status", "AllowInput=false");
- $this->assertCheckBoxes("RatingList", array(3), 6);
+ $this->assertText("{$base}Status", "AllowInput=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(3), 6);
}
function testReadOnly()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListReadOnlyTest");
- $this->verifyTextPresent("TActiveRatingList ReadOnly Test Case");
- $this->assertText("Status", "ReadOnly=true");
- $this->assertCheckBoxes("RatingList", array(0), 6);
+ $this->url("active-controls/index.php?page=ActiveRatingListReadOnlyTest");
+ $this->assertTextPresent("TActiveRatingList ReadOnly Test Case");
+ $this->assertText("{$base}Status", "ReadOnly=true");
+ $this->assertCheckBoxes("{$base}RatingList", array(0), 6);
- $this->clickTD("RatingList_c4");
+ $this->clickTD("{$base}RatingList_c4");
$this->pause(800);
- $this->assertText("Status", "ReadOnly=true");
- $this->assertCheckBoxes("RatingList", array(0), 6);
-
+ $this->assertText("{$base}Status", "ReadOnly=true");
+ $this->assertCheckBoxes("{$base}RatingList", array(0), 6);
+
// Then set ReadOnly to false, and make sure it works.
- $this->click("Writable");
+ $this->click("{$base}Writable");
$this->pause(800);
- $this->assertText("Status", "ReadOnly=false");
- $this->assertCheckBoxes("RatingList", array(0), 6);
-
-
- $this->clickTD("RatingList_c1");
+ $this->assertText("{$base}Status", "ReadOnly=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(0), 6);
+
+
+ $this->clickTD("{$base}RatingList_c1");
$this->pause(800);
- $this->assertText("Status", "2 : Fair");
- $this->assertCheckBoxes("RatingList", array(1), 6);
-
+ $this->assertText("{$base}Status", "2 : Fair");
+ $this->assertCheckBoxes("{$base}RatingList", array(1), 6);
+
// Then set ReadOnly to true, and make sure it doesn't work anymore.
- $this->click("ReadOnly");
+ $this->click("{$base}ReadOnly");
$this->pause(800);
- $this->assertText("Status", "ReadOnly=true");
- $this->assertCheckBoxes("RatingList", array(1), 6);
-
-
- $this->clickTD("RatingList_c2");
+ $this->assertText("{$base}Status", "ReadOnly=true");
+ $this->assertCheckBoxes("{$base}RatingList", array(1), 6);
+
+
+ $this->clickTD("{$base}RatingList_c2");
$this->pause(800);
- $this->assertText("Status", "ReadOnly=true");
- $this->assertCheckBoxes("RatingList", array(1), 6);
+ $this->assertText("{$base}Status", "ReadOnly=true");
+ $this->assertCheckBoxes("{$base}RatingList", array(1), 6);
}
function testEnabled()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListEnabledTest");
- $this->verifyTextPresent("TActiveRatingList Enabled Test Case");
- $this->assertText("Status", "Enabled=false");
- $this->assertCheckBoxes("RatingList", array(5), 6);
+ $this->url("active-controls/index.php?page=ActiveRatingListEnabledTest");
+ $this->assertTextPresent("TActiveRatingList Enabled Test Case");
+ $this->assertText("{$base}Status", "Enabled=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(5), 6);
- $this->clickTD("RatingList_c4");
+ $this->clickTD("{$base}RatingList_c4");
$this->pause(800);
- $this->assertText("Status", "Enabled=false");
- $this->assertCheckBoxes("RatingList", array(5), 6);
-
+ $this->assertText("{$base}Status", "Enabled=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(5), 6);
+
// Then set Enable to true, and make sure it works.
- $this->click("Enable");
+ $this->click("{$base}Enable");
$this->pause(800);
- $this->assertText("Status", "Enabled=true");
- $this->assertCheckBoxes("RatingList", array(5), 6);
-
-
- $this->clickTD("RatingList_c3");
+ $this->assertText("{$base}Status", "Enabled=true");
+ $this->assertCheckBoxes("{$base}RatingList", array(5), 6);
+
+
+ $this->clickTD("{$base}RatingList_c3");
$this->pause(800);
- $this->assertText("Status", "4 : Good");
- $this->assertCheckBoxes("RatingList", array(3), 6);
-
+ $this->assertText("{$base}Status", "4 : Good");
+ $this->assertCheckBoxes("{$base}RatingList", array(3), 6);
+
// Then set Enable to false, and make sure it doesn't work anymore.
- $this->click("Disable");
+ $this->click("{$base}Disable");
$this->pause(800);
- $this->assertText("Status", "Enabled=false");
- $this->assertCheckBoxes("RatingList", array(3), 6);
-
-
- $this->clickTD("RatingList_c5");
+ $this->assertText("{$base}Status", "Enabled=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(3), 6);
+
+
+ $this->clickTD("{$base}RatingList_c5");
$this->pause(800);
- $this->assertText("Status", "Enabled=false");
- $this->assertCheckBoxes("RatingList", array(3), 6);
+ $this->assertText("{$base}Status", "Enabled=false");
+ $this->assertCheckBoxes("{$base}RatingList", array(3), 6);
}
-
+
function testHoverCaption()
{
+ $base='ctl0_Content_';
// Verify we're on the right page.
- $this->open("active-controls/index.php?page=ActiveRatingListHoverCaptionTest");
- $this->verifyTextPresent("TActiveRatingList Hover Caption Test Case");
- $this->assertText("Status", "CaptionID='Status'");
- $this->assertElementPresent("//input[@id='RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c2']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[contains(@class, 'rating_half')]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c4']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c5']/../../../td[contains(@class, 'rating')]");
-
- $this->mouseOver("//input[@id='RatingList_c4']/../../");
- $this->assertText("Status", "Excellent");
- $this->assertElementPresent("//input[@id='RatingList_c0']/../../../td[contains(@class, 'rating_hover')]");
- $this->assertElementPresent("//input[@id='RatingList_c1']/../../../td[contains(@class, 'rating_hover')]");
- $this->assertElementPresent("//input[@id='RatingList_c2']/../../../td[contains(@class, 'rating_hover')]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[contains(@class, 'rating_hover')]");
- $this->assertElementPresent("//input[@id='RatingList_c4']/../../../td[contains(@class, 'rating_hover')]");
- $this->assertElementPresent("//input[@id='RatingList_c5']/../../../td[not(contains(@class, 'rating_hover'))]");
- $this->assertElementPresent("//input[@id='RatingList_c5']/../../../td[contains(@class, 'rating')]");
-
- $this->mouseOut("//input[@id='RatingList_c4']/../../");
- $this->assertText("Status", "CaptionID='Status'");
- $this->assertElementPresent("//input[@id='RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c2']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[not(contains(@class, 'rating_selected'))]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c4']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c5']/../../../td[contains(@class, 'rating')]");
-
-
- $this->mouseOver("//input[@id='RatingList_c1']/../../");
- $this->assertText("Status", "Fair");
-
- $this->click("//input[@id='RatingList_c1']/../../");
- $this->pause(800);
- $this->assertText("Status", "2 : Fair");
- $this->assertElementPresent("//input[@id='RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
- $this->assertElementPresent("//input[@id='RatingList_c2']/../../../td[not(contains(@class, 'rating_selected'))]");
- $this->assertElementPresent("//input[@id='RatingList_c2']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c3']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c4']/../../../td[contains(@class, 'rating')]");
- $this->assertElementPresent("//input[@id='RatingList_c5']/../../../td[contains(@class, 'rating')]");
+ $this->url("active-controls/index.php?page=ActiveRatingListHoverCaptionTest");
+ $this->assertTextPresent("TActiveRatingList Hover Caption Test Case");
+ $this->assertText("{$base}Status", "CaptionID='Status'");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c2']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[contains(@class, 'rating_half')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c4']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c5']/../../../td[contains(@class, 'rating')]");
+
+ $this->mouseOver("//input[@id='{$base}RatingList_c4']/../..");
+ $this->assertText("{$base}Status", "Excellent");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c0']/../../../td[contains(@class, 'rating_hover')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c1']/../../../td[contains(@class, 'rating_hover')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c2']/../../../td[contains(@class, 'rating_hover')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[contains(@class, 'rating_hover')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c4']/../../../td[contains(@class, 'rating_hover')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c5']/../../../td[not(contains(@class, 'rating_hover'))]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c5']/../../../td[contains(@class, 'rating')]");
+
+ $this->mouseOut("//input[@id='{$base}RatingList_c4']/../..");
+ $this->assertText("{$base}Status", "CaptionID='Status'");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c2']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[not(contains(@class, 'rating_selected'))]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c4']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c5']/../../../td[contains(@class, 'rating')]");
+
+
+ $this->mouseOver("//input[@id='{$base}RatingList_c1']/../..");
+ $this->assertText("{$base}Status", "Fair");
+
+ $this->click("//input[@id='{$base}RatingList_c1']/../..");
+ $this->pause(800);
+ $this->assertText("{$base}Status", "2 : Fair");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c0']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c1']/../../../td[contains(@class, 'rating_selected')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c2']/../../../td[not(contains(@class, 'rating_selected'))]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c2']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c3']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c4']/../../../td[contains(@class, 'rating')]");
+ $this->assertElementPresent("//input[@id='{$base}RatingList_c5']/../../../td[contains(@class, 'rating')]");
}
-
+
function clickTD($clientID){
$this->click("//input[@id='{$clientID}']/../..");
}
diff --git a/tests/FunctionalTests/features/protected/pages/I18N/BasicI18N.php b/tests/FunctionalTests/features/protected/pages/I18N/BasicI18N.php
index d4a98e26..49a5db93 100755
--- a/tests/FunctionalTests/features/protected/pages/I18N/BasicI18N.php
+++ b/tests/FunctionalTests/features/protected/pages/I18N/BasicI18N.php
@@ -22,23 +22,23 @@ class BasicI18N extends TPage
* @version $Revision: 1.66 $ $Date: ${DATE} ${TIME} $
* @package ${package}
*//*
-class BasicI18NTestCase extends PradoGenericSeleniumTest
+class BasicI18NTestCase extends PradoGenericSelenium2Test
{
function setup()
{
$page = Prado::getApplication()->getTestPage(__FILE__);
- $this->open($page);
+ $this->url($page);
}
function testI18N()
{
$this->verifyTitle("Basic I18N Test", "");
- $this->verifyTextPresent("Hello", "");
- $this->verifyTextPresent("US$10,000.00", "");
- $this->verifyTextPresent("2006年1月15日 上午12时00分00秒", "");
- $this->verifyTextPresent("None", "");
- $this->verifyTextPresent("One thing.", "");
- $this->verifyTextPresent("Many things.", "");
+ $this->assertTextPresent("Hello", "");
+ $this->assertTextPresent("US$10,000.00", "");
+ $this->assertTextPresent("2006年1月15日 上午12时00分00秒", "");
+ $this->assertTextPresent("None", "");
+ $this->assertTextPresent("One thing.", "");
+ $this->assertTextPresent("Many things.", "");
}
}
*/ \ No newline at end of file
diff --git a/tests/FunctionalTests/features/tests/MyTestCase.php b/tests/FunctionalTests/features/tests/MyTestCase.php
index 92b0886a..682462fe 100755
--- a/tests/FunctionalTests/features/tests/MyTestCase.php
+++ b/tests/FunctionalTests/features/tests/MyTestCase.php
@@ -1,10 +1,10 @@
<?php
-class MyTestCase extends PradoGenericSeleniumTest
+class MyTestCase extends PradoGenericSelenium2Test
{
function test1()
{
- $this->open('http://127.0.0.1');
+ $this->url('http://127.0.0.1');
$this->assertTextNotPresent('asd');
}
}
diff --git a/tests/FunctionalTests/quickstart/ActiveControls/ActiveButtonTestCase.php b/tests/FunctionalTests/quickstart/ActiveControls/ActiveButtonTestCase.php
index 03861440..dce8f144 100755
--- a/tests/FunctionalTests/quickstart/ActiveControls/ActiveButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/ActiveControls/ActiveButtonTestCase.php
@@ -1,36 +1,36 @@
<?php
//$Id: ActiveButtonTestCase.php 3187 2012-07-12 11:21:01Z ctrlaltca $
-class QuickstartActiveButtonTestCase extends PradoGenericSeleniumTest
+class QuickstartActiveButtonTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveButton.Home&amp;notheme=true&amp;lang=en");
+ $this->url("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveButton.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
$this->assertTextPresent('TActiveButton Samples (AJAX)');
// a click button
- $this->verifyElementNotPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
+ $this->assertElementNotPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
$this->click("//input[@type='submit' and @value='click me']", "");
$this->pause(800);
- $this->verifyElementPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
+ $this->assertElementPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
// a command button
- $this->verifyElementNotPresent("//input[@type='submit' and @value=\"Name: test, Param: value using callback\"]");
+ $this->assertElementNotPresent("//input[@type='submit' and @value=\"Name: test, Param: value using callback\"]");
$this->click("//input[@type='submit' and @value='click me']", "");
$this->pause(800);
- $this->verifyElementPresent("//input[@type='submit' and @value=\"Name: test, Param: value using callback\"]");
+ $this->assertElementPresent("//input[@type='submit' and @value=\"Name: test, Param: value using callback\"]");
// a button causing validation
- $this->verifyNotVisible('ctl0_body_ctl2');
+ $this->assertNotVisible('ctl0_body_ctl2');
$this->click("//input[@type='submit' and @value='submit']", "");
$this->pause(800);
- $this->verifyVisible('ctl0_body_ctl2');
+ $this->assertVisible('ctl0_body_ctl2');
$this->type("ctl0\$body\$TextBox", "test");
$this->click("//input[@type='submit' and @value='submit']", "");
$this->pause(800);
- $this->verifyNotVisible('ctl0_body_ctl2');
- $this->verifyElementPresent("//input[@type='submit' and @value=\"I'm clicked using callback\"]", "");
+ $this->assertNotVisible('ctl0_body_ctl2');
+ $this->assertElementPresent("//input[@type='submit' and @value=\"I'm clicked using callback\"]", "");
}
}
diff --git a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
index 257917ec..64643d9d 100755
--- a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCheckBoxTestCase.php
@@ -1,12 +1,11 @@
<?php
//$Id: ActiveCheckBoxTestCase.php 3187 2012-07-12 11:21:01Z ctrlaltca $
-class QuickstartActiveCheckBoxTestCase extends PradoGenericSeleniumTest
+class QuickstartActiveCheckBoxTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->setSpeed(500);
- $this->open("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveCheckBox.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveCheckBox.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -14,45 +13,45 @@ class QuickstartActiveCheckBoxTestCase extends PradoGenericSeleniumTest
// an auto postback checkbox
- $this->verifyTextNotPresent("ctl0_body_ctl0 clicked using callback");
+ $this->assertTextNotPresent("ctl0_body_ctl0 clicked using callback");
$this->click("//input[@name='ctl0\$body\$ctl0']");
$this->pause(800);
$this->assertChecked("//input[@name='ctl0\$body\$ctl0']");
- $this->verifyTextPresent("ctl0_body_ctl0 clicked using callback");
+ $this->assertTextPresent("ctl0_body_ctl0 clicked using callback");
$this->click("//input[@name='ctl0\$body\$ctl0']");
$this->pause(800);
- $this->verifyTextPresent("ctl0_body_ctl0 clicked using callback");
+ $this->assertTextPresent("ctl0_body_ctl0 clicked using callback");
$this->assertNotChecked("//input[@name='ctl0\$body\$ctl0']");
// a checkbox causing validation on a textbox
- $this->verifyNotVisible('ctl0_body_ctl1');
+ $this->assertNotVisible('ctl0_body_ctl1');
$this->click("//input[@name='ctl0\$body\$ctl2']");
- $this->verifyVisible('ctl0_body_ctl1');
+ $this->assertVisible('ctl0_body_ctl1');
$this->click("//input[@name='ctl0\$body\$ctl2']", "");
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->type("ctl0\$body\$TextBox", "test");
$this->click("//input[@name='ctl0\$body\$ctl2']", "");
$this->pause(800);
- $this->verifyNotVisible('ctl0_body_ctl1');
+ $this->assertNotVisible('ctl0_body_ctl1');
$this->assertTextPresent("ctl0_body_ctl2 clicked using callback");
// a checkbox validated by a required field validator
$this->assertNotChecked("//input[@name='ctl0\$body\$CheckBox']");
- $this->verifyNotVisible('ctl0_body_ctl4');
+ $this->assertNotVisible('ctl0_body_ctl4');
$this->click("//input[@type='submit' and @value='Submit']", "");
- $this->verifyVisible('ctl0_body_ctl4');
+ $this->assertVisible('ctl0_body_ctl4');
$this->click("//input[@name='ctl0\$body\$CheckBox']", "");
$this->assertChecked("//input[@name='ctl0\$body\$CheckBox']");
$this->click("//input[@type='submit' and @value='Submit']", "");
- $this->verifyNotVisible('ctl0_body_ctl4');
+ $this->pause(800);
+ $this->assertNotVisible('ctl0_body_ctl4');
$this->assertTextPresent("ctl0_body_CheckBox clicked");
// a checkbox validated by a required field validator using AutoPostBack
$this->assertChecked("//input[@name='ctl0\$body\$CheckBox2']");
- $this->verifyNotVisible('ctl0_body_ctl5');
+ $this->assertNotVisible('ctl0_body_ctl5');
$this->click("//input[@name='ctl0\$body\$CheckBox2']", "");
- $this->verifyVisible('ctl0_body_ctl5');
+ $this->assertVisible('ctl0_body_ctl5');
$this->assertChecked("//input[@name='ctl0\$body\$CheckBox2']");
- $this->setSpeed(0);
}
}
diff --git a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCustomValidatorTestCase.php b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCustomValidatorTestCase.php
index 967842b0..dba29133 100755
--- a/tests/FunctionalTests/quickstart/ActiveControls/ActiveCustomValidatorTestCase.php
+++ b/tests/FunctionalTests/quickstart/ActiveControls/ActiveCustomValidatorTestCase.php
@@ -1,10 +1,10 @@
<?php
//$Id: ActiveButtonTestCase.php 1405 2006-09-10 01:03:56Z wei $
-class QuickstartActiveCustomValidatorTestCase extends PradoGenericSeleniumTest
+class QuickstartActiveCustomValidatorTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveCustomValidator.Home&amp;notheme=true&amp;lang=en");
+ $this->url("../../demos/quickstart/index.php?page=ActiveControls.Samples.TActiveCustomValidator.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
diff --git a/tests/FunctionalTests/quickstart/Advanced/I18N.php b/tests/FunctionalTests/quickstart/Advanced/I18N.php
index 726501ce..51df9503 100755
--- a/tests/FunctionalTests/quickstart/Advanced/I18N.php
+++ b/tests/FunctionalTests/quickstart/Advanced/I18N.php
@@ -1,52 +1,52 @@
<?php
//New Test
-class QuickstartI18NTestCase extends PradoGenericSeleniumTest
+class QuickstartI18NTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?notheme=true&page=Advanced.Samples.I18N.Home&amp;lang=en&amp;notheme=true", "");
- $this->verifyTextPresent("Internationlization in PRADO", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("$12.40", "");
- $this->verifyTextPresent("€100.00", "");
- $this->verifyTextPresent("December 6, 2004", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=zh&amp;notheme=true", "");
- $this->verifyTextPresent("PRADO 国际化", "");
- $this->verifyTextPresent("2004 十二月", "");
- $this->verifyTextPresent("US$ 12.40", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00 ", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=zh_TW&amp;notheme=true", "");
- $this->verifyTextPresent("PRADO 國際化", "");
- $this->verifyTextPresent("2004年12月6日", "");
- $this->verifyTextPresent("US$12.40", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=de&amp;notheme=true", "");
- $this->verifyTextPresent("Internationalisierung in PRADO", "");
- $this->verifyTextPresent("6. Dezember 2004 ", "");
- $this->verifyTextPresent("$ 12,40", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=es&amp;notheme=true", "");
- $this->verifyTextPresent("Internationlization en PRADO", "");
- $this->verifyTextPresent("6 de diciembre de 2004", "");
- $this->verifyTextPresent("US$12.40", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=fr&amp;notheme=true", "");
- $this->verifyTextPresent("Internationalisation avec PRADO", "");
- $this->verifyTextPresent("6 décembre 2004", "");
- $this->verifyTextPresent("12,40 $", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00", "");
- $this->open("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=pl&amp;notheme=true", "");
- $this->verifyTextPresent("Internacjonalizacja w PRADO", "");
- $this->verifyTextPresent("6 grudnia 2004", "");
- $this->verifyTextPresent("US$ 12,40", "");
- $this->verifyTextPresent("46.412,42 €", "");
- $this->verifyTextPresent("€100.00", "");
+ $this->url("../../demos/quickstart/index.php?notheme=true&page=Advanced.Samples.I18N.Home&amp;lang=en&amp;notheme=true");
+ $this->assertTextPresent("Internationlization in PRADO", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("$12.40", "");
+ $this->assertTextPresent("€100.00", "");
+ $this->assertTextPresent("December 6, 2004", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=zh&amp;notheme=true");
+ $this->assertTextPresent("PRADO 国际化", "");
+ $this->assertTextPresent("2004 十二月", "");
+ $this->assertTextPresent("US$ 12.40", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00 ", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=zh_TW&amp;notheme=true");
+ $this->assertTextPresent("PRADO 國際化", "");
+ $this->assertTextPresent("2004年12月6日", "");
+ $this->assertTextPresent("US$12.40", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=de&amp;notheme=true");
+ $this->assertTextPresent("Internationalisierung in PRADO", "");
+ $this->assertTextPresent("6. Dezember 2004 ", "");
+ $this->assertTextPresent("$ 12,40", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=es&amp;notheme=true");
+ $this->assertTextPresent("Internationlization en PRADO", "");
+ $this->assertTextPresent("6 de diciembre de 2004", "");
+ $this->assertTextPresent("US$12.40", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=fr&amp;notheme=true");
+ $this->assertTextPresent("Internationalisation avec PRADO", "");
+ $this->assertTextPresent("6 décembre 2004", "");
+ $this->assertTextPresent("12,40 $", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00", "");
+ $this->url("../../demos/quickstart/index.php?page=Advanced.Samples.I18N.Home&amp;lang=pl&amp;notheme=true");
+ $this->assertTextPresent("Internacjonalizacja w PRADO", "");
+ $this->assertTextPresent("6 grudnia 2004", "");
+ $this->assertTextPresent("US$ 12,40", "");
+ $this->assertTextPresent("46.412,42 €", "");
+ $this->assertTextPresent("€100.00", "");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/BulletedListTestCase.php b/tests/FunctionalTests/quickstart/Controls/BulletedListTestCase.php
index 0b272428..f5b58b48 100755
--- a/tests/FunctionalTests/quickstart/Controls/BulletedListTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/BulletedListTestCase.php
@@ -1,36 +1,36 @@
<?php
-class QuickstartBulletedListTestCase extends PradoGenericSeleniumTest
+class QuickstartBulletedListTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TBulletedList.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TBulletedList.Home&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('item 1','');
- $this->verifyTextPresent('item 2','');
- $this->verifyTextPresent('item 3','');
- $this->verifyTextPresent('item 4','');
- $this->verifyTextPresent('google','');
- $this->verifyTextPresent('yahoo','');
- $this->verifyTextPresent('amazon','');
+ $this->assertTextPresent('item 1','');
+ $this->assertTextPresent('item 2','');
+ $this->assertTextPresent('item 3','');
+ $this->assertTextPresent('item 4','');
+ $this->assertTextPresent('google','');
+ $this->assertTextPresent('yahoo','');
+ $this->assertTextPresent('amazon','');
// verify order list starting from 5
- $this->verifyElementPresent("//ol[@start='5']");
+ $this->assertElementPresent("//ol[@start='5']");
// unable to verify styles
// verify hyperlink list
- $this->verifyElementPresent("//a[@href='http://www.google.com/']");
- $this->verifyElementPresent("//a[@href='http://www.yahoo.com/']");
- $this->verifyElementPresent("//a[@href='http://www.amazon.com/']");
+ $this->assertElementPresent("//a[@href='http://www.google.com/']");
+ $this->assertElementPresent("//a[@href='http://www.yahoo.com/']");
+ $this->assertElementPresent("//a[@href='http://www.amazon.com/']");
// verify linkbutton list
$this->clickAndWait("id=ctl0_body_ctl40", "");
- $this->verifyTextPresent("You clicked google : http://www.google.com/.", "");
+ $this->assertTextPresent("You clicked google : http://www.google.com/.", "");
$this->clickAndWait("id=ctl0_body_ctl41", "");
- $this->verifyTextPresent("You clicked yahoo : http://www.yahoo.com/.", "");
+ $this->assertTextPresent("You clicked yahoo : http://www.yahoo.com/.", "");
$this->clickAndWait("id=ctl0_body_ctl42", "");
- $this->verifyTextPresent("You clicked amazon : http://www.amazon.com/.", "");
+ $this->assertTextPresent("You clicked amazon : http://www.amazon.com/.", "");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/ButtonTestCase.php b/tests/FunctionalTests/quickstart/Controls/ButtonTestCase.php
index ad84e1d0..f228de83 100755
--- a/tests/FunctionalTests/quickstart/Controls/ButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/ButtonTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartButtonTestCase extends PradoGenericSeleniumTest
+class QuickstartButtonTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TButton.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TButton.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -12,22 +12,22 @@ class QuickstartButtonTestCase extends PradoGenericSeleniumTest
$this->clickAndWait("//input[@type='submit' and @value='text']", "");
// a click button
- $this->verifyElementNotPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
+ $this->assertElementNotPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
$this->clickAndWait("//input[@type='submit' and @value='click me']", "");
- $this->verifyElementPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
+ $this->assertElementPresent("//input[@type='submit' and @value=\"I'm clicked\"]");
// a command button
- $this->verifyElementNotPresent("//input[@type='submit' and @value=\"Name: test, Param: value\"]");
+ $this->assertElementNotPresent("//input[@type='submit' and @value=\"Name: test, Param: value\"]");
$this->clickAndWait("//input[@type='submit' and @value='click me']", "");
- $this->verifyElementPresent("//input[@type='submit' and @value=\"Name: test, Param: value\"]");
+ $this->assertElementPresent("//input[@type='submit' and @value=\"Name: test, Param: value\"]");
// a button causing validation
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
$this->click("//input[@type='submit' and @value='submit']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@type='submit' and @value='submit']", "");
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/CheckBoxListTestCase.php b/tests/FunctionalTests/quickstart/Controls/CheckBoxListTestCase.php
index 242bc815..6ab6329b 100755
--- a/tests/FunctionalTests/quickstart/Controls/CheckBoxListTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/CheckBoxListTestCase.php
@@ -1,11 +1,11 @@
<?php
//New Test
-class QuickstartCheckBoxListTestCase extends PradoGenericSeleniumTest
+class QuickstartCheckBoxListTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TCheckBoxList.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TCheckBoxList.Home&amp;notheme=true&amp;lang=en");
// Check box list with default settings:
$this->click("//input[@name='ctl0\$body\$ctl0\$c0' and @value='value 1']", "");
@@ -22,31 +22,31 @@ class QuickstartCheckBoxListTestCase extends PradoGenericSeleniumTest
// Check box list's behavior upon postback
$this->click("//input[@name='ctl0\$body\$CheckBoxList\$c2' and @value='value 3']", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyTextPresent("Your selection is: (Index: 1, Value: value 2, Text: item 2)(Index: 2, Value: value 3, Text: item 3)(Index: 4, Value: value 5, Text: item 5)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: value 2, Text: item 2)(Index: 2, Value: value 3, Text: item 3)(Index: 4, Value: value 5, Text: item 5)", "");
// Auto postback check box list
$this->clickAndWait("//input[@name='ctl0\$body\$ctl7\$c1' and @value='value 2']", "");
- $this->verifyTextPresent("Your selection is: (Index: 4, Value: value 5, Text: item 5)", "");
+ $this->assertTextPresent("Your selection is: (Index: 4, Value: value 5, Text: item 5)", "");
// Databind to an integer-indexed array
$this->clickAndWait("//input[@name='ctl0\$body\$DBCheckBoxList1\$c1' and @value='1']", "");
- $this->verifyTextPresent("Your selection is: (Index: 1, Value: 1, Text: item 2)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: 1, Text: item 2)", "");
// Databind to an associative array:
$this->clickAndWait("//input[@name='ctl0\$body\$DBCheckBoxList2\$c1' and @value='key 2']", "");
- $this->verifyTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
// Databind with DataTextField and DataValueField specified
$this->clickAndWait("//input[@name='ctl0\$body\$DBCheckBoxList3\$c2' and @value='003']", "");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
// CheckBox list causing validation
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
$this->click("//input[@name='ctl0\$body\$ctl9\$c0' and @value='Agree']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl8');
+ $this->assertVisible('ctl0_body_ctl8');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl9\$c0' and @value='Agree']", "");
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/CheckBoxTestCase.php b/tests/FunctionalTests/quickstart/Controls/CheckBoxTestCase.php
index 57b50dd9..1bacecb0 100755
--- a/tests/FunctionalTests/quickstart/Controls/CheckBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/CheckBoxTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartCheckBoxTestCase extends PradoGenericSeleniumTest
+class QuickstartCheckBoxTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TCheckBox.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TCheckBox.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -15,39 +15,39 @@ class QuickstartCheckBoxTestCase extends PradoGenericSeleniumTest
$this->click("//input[@name='ctl0\$body\$ctl1' and @value='value']", "");
// an auto postback checkbox
- $this->verifyTextNotPresent("I'm clicked");
+ $this->assertTextNotPresent("I'm clicked");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl2']", "");
- $this->verifyTextPresent("I'm clicked");
+ $this->assertTextPresent("I'm clicked");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl2']", "");
- $this->verifyTextPresent("I'm clicked");
+ $this->assertTextPresent("I'm clicked");
// a checkbox causing validation on a textbox
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl4']", "");
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
// a checkbox validated by a required field validator
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
$this->click("//input[@type='submit' and @value='Submit']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl6');
+ $this->assertVisible('ctl0_body_ctl6');
$this->click("//input[@name='ctl0\$body\$CheckBox']", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
// a checkbox validated by a required field validator using AutoPostBack
- $this->verifyNotVisible('ctl0_body_ctl7');
+ $this->assertNotVisible('ctl0_body_ctl7');
$this->click("//input[@name='ctl0\$body\$CheckBox2']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl7');
+ $this->assertVisible('ctl0_body_ctl7');
// $this->clickAndWait("//input[@name='ctl0\$body\$CheckBox2' and @value='ctl0\$body\$CheckBox2']", "");
-// $this->verifyNotVisible('ctl0_body_ctl7');
+// $this->assertNotVisible('ctl0_body_ctl7');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid1TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid1TestCase.php
index 57ee92ae..efe2829d 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid1TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid1TestCase.php
@@ -1,29 +1,29 @@
<?php
-class QuickstartDataGrid1TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid1TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample1&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample1&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('id','');
- $this->verifyTextPresent('name','');
- $this->verifyTextPresent('quantity','');
- $this->verifyTextPresent('price','');
- $this->verifyTextPresent('imported','');
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('Motherboard','');
- $this->verifyTextPresent('100','');
- $this->verifyTextPresent('true','');
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextPresent('Speaker','');
- $this->verifyTextPresent('35','');
- $this->verifyTextPresent('65','');
- $this->verifyTextPresent('false','');
+ $this->assertTextPresent('id','');
+ $this->assertTextPresent('name','');
+ $this->assertTextPresent('quantity','');
+ $this->assertTextPresent('price','');
+ $this->assertTextPresent('imported','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('Motherboard','');
+ $this->assertTextPresent('100','');
+ $this->assertTextPresent('true','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextPresent('Speaker','');
+ $this->assertTextPresent('35','');
+ $this->assertTextPresent('65','');
+ $this->assertTextPresent('false','');
// verify specific table tags
- $this->verifyElementPresent("ctl0_body_DataGrid");
+ $this->assertElementPresent("ctl0_body_DataGrid");
$this->verifyAttribute("ctl0_body_DataGrid@cellpadding","2");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
index 7efd69cc..15a4c510 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid2TestCase.php
@@ -1,49 +1,49 @@
<?php
-class QuickstartDataGrid2TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid2TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample2&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample2&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('Book Title','');
- $this->verifyTextPresent('Publisher','');
- $this->verifyTextPresent('Price','');
- $this->verifyTextPresent('In-stock','');
- $this->verifyTextPresent('Rating','');
+ $this->assertTextPresent('Book Title','');
+ $this->assertTextPresent('Publisher','');
+ $this->assertTextPresent('Price','');
+ $this->assertTextPresent('In-stock','');
+ $this->assertTextPresent('Rating','');
// verify book titles
- $this->verifyElementPresent("//a[@href='http://www.amazon.com/gp/product/0596007124' and text()='Head First Design Patterns']",'');
- $this->verifyElementPresent("//a[@href='http://www.amazon.com/gp/product/0321278658' and text()='Extreme Programming Explained : Embrace Change']",'');
+ $this->assertElementPresent("//a[@href='http://www.amazon.com/gp/product/0596007124' and text()='Head First Design Patterns']",'');
+ $this->assertElementPresent("//a[@href='http://www.amazon.com/gp/product/0321278658' and text()='Extreme Programming Explained : Embrace Change']",'');
// verify publishers
- $this->verifyTextPresent("O'Reilly Media, Inc.",'');
- $this->verifyTextPresent("Addison-Wesley Professional",'');
+ $this->assertTextPresent("O'Reilly Media, Inc.",'');
+ $this->assertTextPresent("Addison-Wesley Professional",'');
// verify prices
- $this->verifyTextPresent("\$37.49",'');
- $this->verifyTextPresent("\$38.49",'');
+ $this->assertTextPresent("\$37.49",'');
+ $this->assertTextPresent("\$38.49",'');
// verify in-stock
$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->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl6_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@checked',null);
$this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@disabled','regexp:true|disabled');
// verify ratings
- //$this->verifyElementPresent("//img[@src='images/star5.gif']",'');
- //$this->verifyElementPresent("//img[@src='images/star2.gif']",'');
+ //$this->assertElementPresent("//img[@src='images/star5.gif']",'');
+ //$this->assertElementPresent("//img[@src='images/star2.gif']",'');
// verify toggle column visibility
$this->clickAndWait("//input[@name='ctl0\$body\$ctl1\$c0' and @value='Book Title']", "");
- $this->verifyTextNotPresent('Head First Design Patterns','');
+ $this->assertTextNotPresent('Head First Design Patterns','');
$this->clickAndWait("//input[@name='ctl0\$body\$ctl1\$c3' and @value='In-stock']", "");
- $this->verifyElementNotPresent('ctl0_body_DataGrid_ctl1_ctl5','');
+ $this->assertElementNotPresent('ctl0_body_DataGrid_ctl1_ctl5','');
$this->clickAndWait("//input[@name='ctl0\$body\$ctl1\$c3' and @value='In-stock']", "");
- $this->verifyElementPresent('ctl0_body_DataGrid_ctl1_ctl5','');
+ $this->assertElementPresent('ctl0_body_DataGrid_ctl1_ctl5','');
$this->clickAndWait("//input[@name='ctl0\$body\$ctl1\$c0' and @value='Book Title']", "");
- $this->verifyTextPresent('Head First Design Patterns','');
+ $this->assertTextPresent('Head First Design Patterns','');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
index 2cdace20..0b24e2f5 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid3TestCase.php
@@ -1,18 +1,18 @@
<?php
-class QuickstartDataGrid3TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid3TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample3&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample3&amp;notheme=true&amp;lang=en");
// verify the 2nd row of data
- $this->verifyTextPresent("Design Patterns: Elements of Reusable Object-Oriented Software", "");
- $this->verifyTextPresent("Addison-Wesley Professional", "");
- $this->verifyTextPresent("$47.04", "");
+ $this->assertTextPresent("Design Patterns: Elements of Reusable Object-Oriented Software", "");
+ $this->assertTextPresent("Addison-Wesley Professional", "");
+ $this->assertTextPresent("$47.04", "");
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl4@checked','regexp:true|checked');
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl4@disabled','regexp:true|disabled');
- //$this->verifyElementPresent("//img[@src='images/star5.gif']",'');
+ //$this->assertElementPresent("//img[@src='images/star5.gif']",'');
// edit the 2nd row
$this->clickAndWait("id=ctl0_body_DataGrid_ctl2_ctl7", "");
@@ -24,27 +24,26 @@ class QuickstartDataGrid3TestCase extends PradoGenericSeleniumTest
$this->clickAndWait("link=Save", "");
// verify the 2nd row is saved
- $this->verifyTextPresent("Design Pattern: Elements of Reusable Object-Oriented Software", "");
- $this->verifyTextPresent("Addison Wesley Professional", "");
- $this->verifyTextPresent("$57.04", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl2_ctl4").hasAttribute("checked")'), 'false');
+ $this->assertTextPresent("Design Pattern: Elements of Reusable Object-Oriented Software", "");
+ $this->assertTextPresent("Addison Wesley Professional", "");
+ $this->assertTextPresent("$57.04", "");
+ $this->verifyAttribute("ctl0_body_DataGrid_ctl2_ctl4@checked", null);
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl4@disabled','regexp:true|disabled');
- //$this->verifyElementPresent("//img[@src='images/star1.gif']",'');
+ //$this->assertElementPresent("//img[@src='images/star1.gif']",'');
// verify cancel editting the 3rd row
$this->clickAndWait("id=ctl0_body_DataGrid_ctl3_ctl7", "");
$this->clickAndWait("link=Cancel", "");
- $this->verifyTextPresent("Design Patterns Explained : A New Perspective on Object-Oriented Design", "");
+ $this->assertTextPresent("Design Patterns Explained : A New Perspective on Object-Oriented Design", "");
// verify deleting
$this->clickAndWait("id=ctl0_body_DataGrid_ctl3_ctl9", "");
$this->verifyConfirmation("Are you sure?");
- $this->verifyTextNotPresent("Design Patterns Explained : A New Perspective on Object-Oriented Design", "");
+ $this->assertTextNotPresent("Design Patterns Explained : A New Perspective on Object-Oriented Design", "");
- $this->verifyTextPresent("Extreme Programming Explained : Embrace Change",'');
- $this->chooseCancelOnNextConfirmation();
+ $this->assertTextPresent("Extreme Programming Explained : Embrace Change",'');
$this->click("id=ctl0_body_DataGrid_ctl6_ctl9", "");
- $this->verifyConfirmation("Are you sure?");
- $this->verifyTextPresent("Extreme Programming Explained : Embrace Change",'');
+ $this->verifyConfirmationDismiss("Are you sure?");
+ $this->assertTextPresent("Extreme Programming Explained : Embrace Change",'');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
index 702b997e..f78e52c4 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid4TestCase.php
@@ -1,28 +1,28 @@
<?php
-class QuickstartDataGrid4TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid4TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample4&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample4&amp;notheme=true&amp;lang=en");
// verify the 2nd row of data
- $this->verifyTextPresent("Design Patterns: Elements of Reusable Object-Oriented Software", "");
- $this->verifyTextPresent("Addison-Wesley Professional", "");
- $this->verifyTextPresent("$47.04", "");
+ $this->assertTextPresent("Design Patterns: Elements of Reusable Object-Oriented Software", "");
+ $this->assertTextPresent("Addison-Wesley Professional", "");
+ $this->assertTextPresent("$47.04", "");
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl5@checked','regexp:true|checked');
$this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl5@disabled','regexp:true|disabled');
// verify sorting
$this->clickAndWait("link=Book Title", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl1_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@checked', null);
$this->clickAndWait("link=Publisher", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl6_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl6_ctl5@checked', null);
$this->clickAndWait("link=Price", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl2_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl2_ctl5@checked', null);
$this->clickAndWait("link=In-stock", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl1_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl1_ctl5@checked', null);
$this->clickAndWait("link=Rating", "");
- $this->assertEquals($this->getEval('this.browserbot.findElement("ctl0_body_DataGrid_ctl4_ctl5").hasAttribute("checked")'), 'false');
+ $this->verifyAttribute('ctl0_body_DataGrid_ctl4_ctl5@checked', null);
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid5TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid5TestCase.php
index f854d44c..4ff65a64 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid5TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid5TestCase.php
@@ -1,50 +1,50 @@
<?php
-class QuickstartDataGrid5TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid5TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample5&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample5&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
// verify column headers
- $this->verifyTextPresent('id','');
- $this->verifyTextPresent('name','');
- $this->verifyTextPresent('quantity','');
- $this->verifyTextPresent('price','');
- $this->verifyTextPresent('imported','');
+ $this->assertTextPresent('id','');
+ $this->assertTextPresent('name','');
+ $this->assertTextPresent('quantity','');
+ $this->assertTextPresent('price','');
+ $this->assertTextPresent('imported','');
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextPresent('ITN005','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextPresent('ITN005','');
+ $this->assertTextNotPresent('ITN006','');
// verify paging
$this->clickAndWait("link=2", "");
- $this->verifyTextPresent('ITN006','');
- $this->verifyTextPresent('ITN007','');
- $this->verifyTextPresent('ITN008','');
- $this->verifyTextPresent('ITN009','');
- $this->verifyTextPresent('ITN010','');
- $this->verifyTextNotPresent('ITN011','');
- $this->verifyTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN006','');
+ $this->assertTextPresent('ITN007','');
+ $this->assertTextPresent('ITN008','');
+ $this->assertTextPresent('ITN009','');
+ $this->assertTextPresent('ITN010','');
+ $this->assertTextNotPresent('ITN011','');
+ $this->assertTextNotPresent('ITN005','');
$this->clickAndWait("link=4", "");
- $this->verifyTextPresent('ITN016','');
- $this->verifyTextPresent('ITN017','');
- $this->verifyTextPresent('ITN018','');
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextNotPresent('ITN015','');
+ $this->assertTextPresent('ITN016','');
+ $this->assertTextPresent('ITN017','');
+ $this->assertTextPresent('ITN018','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextNotPresent('ITN015','');
$this->clickAndWait("link=1", "");
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextPresent('ITN005','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextPresent('ITN005','');
+ $this->assertTextNotPresent('ITN006','');
// show top pager
$this->clickAndWait("//input[@name='ctl0\$body\$ctl1\$c0' and @value='Top']", "");
@@ -59,55 +59,55 @@ class QuickstartDataGrid5TestCase extends PradoGenericSeleniumTest
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
// verify next prev paging
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextNotPresent('ITN006','');
$this->clickAndWait("link=Next Page", "");
- $this->verifyTextNotPresent('ITN005','');
- $this->verifyTextPresent('ITN006','');
- $this->verifyTextNotPresent('ITN011','');
+ $this->assertTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN006','');
+ $this->assertTextNotPresent('ITN011','');
$this->clickAndWait("link=Next Page", "");
- $this->verifyTextNotPresent('ITN010','');
- $this->verifyTextPresent('ITN011','');
- $this->verifyTextNotPresent('ITN016','');
+ $this->assertTextNotPresent('ITN010','');
+ $this->assertTextPresent('ITN011','');
+ $this->assertTextNotPresent('ITN016','');
$this->clickAndWait("link=Next Page", "");
- $this->verifyTextNotPresent('ITN015','');
- $this->verifyTextPresent('ITN016','');
+ $this->assertTextNotPresent('ITN015','');
+ $this->assertTextPresent('ITN016','');
$this->clickAndWait("link=Prev Page", "");
- $this->verifyTextNotPresent('ITN010','');
- $this->verifyTextPresent('ITN011','');
- $this->verifyTextNotPresent('ITN016','');
+ $this->assertTextNotPresent('ITN010','');
+ $this->assertTextPresent('ITN011','');
+ $this->assertTextNotPresent('ITN016','');
$this->clickAndWait("link=Prev Page", "");
- $this->verifyTextNotPresent('ITN005','');
- $this->verifyTextPresent('ITN006','');
- $this->verifyTextNotPresent('ITN011','');
+ $this->assertTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN006','');
+ $this->assertTextNotPresent('ITN011','');
$this->clickAndWait("link=Prev Page", "");
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextNotPresent('ITN006','');
// change button count
$this->type("ctl0\$body\$PageButtonCount", "2");
$this->clickAndWait("name=ctl0\$body\$ctl6", "");
$this->clickAndWait("link=Next Page", "");
- $this->verifyTextNotPresent('ITN010','');
- $this->verifyTextPresent('ITN011','');
- $this->verifyTextNotPresent('ITN016','');
+ $this->assertTextNotPresent('ITN010','');
+ $this->assertTextPresent('ITN011','');
+ $this->assertTextNotPresent('ITN016','');
$this->clickAndWait("link=4", "");
- $this->verifyTextNotPresent('ITN015','');
- $this->verifyTextPresent('ITN016','');
+ $this->assertTextNotPresent('ITN015','');
+ $this->assertTextPresent('ITN016','');
$this->clickAndWait("link=Prev Page", "");
- $this->verifyTextNotPresent('ITN005','');
- $this->verifyTextPresent('ITN006','');
- $this->verifyTextNotPresent('ITN011','');
+ $this->assertTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN006','');
+ $this->assertTextNotPresent('ITN011','');
$this->type("ctl0\$body\$PageButtonCount", "10");
$this->clickAndWait("name=ctl0\$body\$ctl6", "");
$this->type("ctl0\$body\$PageSize", "2");
$this->clickAndWait("name=ctl0\$body\$ctl8", "");
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextNotPresent('ITN003','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextNotPresent('ITN003','');
$this->clickAndWait("link=10", "");
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextNotPresent('ITN018','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextNotPresent('ITN018','');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataGrid6TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataGrid6TestCase.php
index c6fba20f..8d48fd85 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataGrid6TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataGrid6TestCase.php
@@ -1,48 +1,48 @@
<?php
-class QuickstartDataGrid6TestCase extends PradoGenericSeleniumTest
+class QuickstartDataGrid6TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample6&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataGrid.Sample6&amp;notheme=true&amp;lang=en");
// verify column headers
- $this->verifyTextPresent('id','');
- $this->verifyTextPresent('name','');
- $this->verifyTextPresent('quantity','');
- $this->verifyTextPresent('price','');
- $this->verifyTextPresent('imported','');
+ $this->assertTextPresent('id','');
+ $this->assertTextPresent('name','');
+ $this->assertTextPresent('quantity','');
+ $this->assertTextPresent('price','');
+ $this->assertTextPresent('imported','');
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextPresent('ITN005','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextPresent('ITN005','');
+ $this->assertTextNotPresent('ITN006','');
// verify paging
$this->clickAndWait("link=2", "");
- $this->verifyTextPresent('ITN006','');
- $this->verifyTextPresent('ITN007','');
- $this->verifyTextPresent('ITN008','');
- $this->verifyTextPresent('ITN009','');
- $this->verifyTextPresent('ITN010','');
- $this->verifyTextNotPresent('ITN011','');
- $this->verifyTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN006','');
+ $this->assertTextPresent('ITN007','');
+ $this->assertTextPresent('ITN008','');
+ $this->assertTextPresent('ITN009','');
+ $this->assertTextPresent('ITN010','');
+ $this->assertTextNotPresent('ITN011','');
+ $this->assertTextNotPresent('ITN005','');
$this->clickAndWait("link=4", "");
- $this->verifyTextPresent('ITN016','');
- $this->verifyTextPresent('ITN017','');
- $this->verifyTextPresent('ITN018','');
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextNotPresent('ITN015','');
+ $this->assertTextPresent('ITN016','');
+ $this->assertTextPresent('ITN017','');
+ $this->assertTextPresent('ITN018','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextNotPresent('ITN015','');
$this->clickAndWait("link=1", "");
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextPresent('ITN005','');
- $this->verifyTextNotPresent('ITN006','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextPresent('ITN005','');
+ $this->assertTextNotPresent('ITN006','');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataList1TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataList1TestCase.php
index 4ff6478a..01a3b62a 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataList1TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataList1TestCase.php
@@ -1,24 +1,24 @@
<?php
-class QuickstartDataList1TestCase extends PradoGenericSeleniumTest
+class QuickstartDataList1TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataList.Sample1&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataList.Sample1&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('$100','');
- $this->verifyTextPresent('Motherboard','');
- $this->verifyTextPresent('ITN018','');
- $this->verifyTextPresent('Surge protector','');
- $this->verifyTextPresent('45','');
- $this->verifyTextPresent('$15','');
- $this->verifyTextPresent('Total 19 products.','');
- $this->verifyTextPresent('Computer Parts','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('$100','');
+ $this->assertTextPresent('Motherboard','');
+ $this->assertTextPresent('ITN018','');
+ $this->assertTextPresent('Surge protector','');
+ $this->assertTextPresent('45','');
+ $this->assertTextPresent('$15','');
+ $this->assertTextPresent('Total 19 products.','');
+ $this->assertTextPresent('Computer Parts','');
// verify specific table tags
- $this->verifyElementPresent("ctl0_body_DataList");
- $this->verifyElementPresent("//td[@align='right']");
+ $this->assertElementPresent("ctl0_body_DataList");
+ $this->assertElementPresent("//td[@align='right']");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DataList2TestCase.php b/tests/FunctionalTests/quickstart/Controls/DataList2TestCase.php
index 4fb3743e..2957c96f 100755
--- a/tests/FunctionalTests/quickstart/Controls/DataList2TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DataList2TestCase.php
@@ -1,22 +1,22 @@
<?php
-class QuickstartDataList2TestCase extends PradoGenericSeleniumTest
+class QuickstartDataList2TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDataList.Sample2&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDataList.Sample2&amp;notheme=true&amp;lang=en");
// verify initial presentation
- $this->verifyTextPresent("Motherboard ", "");
- $this->verifyTextPresent("Monitor ", "");
+ $this->assertTextPresent("Motherboard", "");
+ $this->assertTextPresent("Monitor", "");
// verify selecting an item
$this->clickAndWait("link=ITN003", "");
- $this->verifyTextPresent("Quantity", "");
- $this->verifyTextPresent("Price", "");
- $this->verifyTextPresent("\$80", "");
+ $this->assertTextPresent("Quantity", "");
+ $this->assertTextPresent("Price", "");
+ $this->assertTextPresent("\$80", "");
$this->clickAndWait("link=ITN005", "");
- $this->verifyTextPresent("\$150", "");
+ $this->assertTextPresent("\$150", "");
// verify editting an item
$this->clickAndWait("id=ctl0_body_DataList_ctl5_ctl0", "");
@@ -27,8 +27,8 @@ class QuickstartDataList2TestCase extends PradoGenericSeleniumTest
// verify item is saved
$this->clickAndWait("link=ITN005", "");
- $this->verifyTextPresent("\$140.99", "");
- $this->verifyTextPresent("11", "");
+ $this->assertTextPresent("\$140.99", "");
+ $this->assertTextPresent("11", "");
// verify editting another item
$this->clickAndWait("id=ctl0_body_DataList_ctl3_ctl1", "");
@@ -39,21 +39,20 @@ class QuickstartDataList2TestCase extends PradoGenericSeleniumTest
// verify item is canceled
$this->clickAndWait("link=ITN003", "");
- $this->verifyTextPresent("2", "");
- $this->verifyTextPresent("Harddrive ", "");
+ $this->assertTextPresent("2", "");
+ $this->assertTextPresent("Harddrive", "");
// verify item deletion
$this->clickAndWait("id=ctl0_body_DataList_ctl3_ctl1", "");
$this->verifyConfirmation("Are you sure?");
- $this->chooseCancelOnNextConfirmation();
$this->click("id=ctl0_body_DataList_ctl5_ctl2", "");
- $this->verifyConfirmation("Are you sure?");
- $this->verifyTextPresent("Motherboard ", "");
- $this->verifyTextPresent("CPU ", "");
- $this->verifyTextNotPresent("Harddrive","");
- $this->verifyTextPresent("Sound card", "");
- $this->verifyTextPresent("Video card", "");
- $this->verifyTextPresent("Keyboard","");
- $this->verifyTextPresent("Monitor ", "");
+ $this->verifyConfirmationDismiss("Are you sure?");
+ $this->assertTextPresent("Motherboard", "");
+ $this->assertTextPresent("CPU", "");
+ $this->assertTextNotPresent("Harddrive","");
+ $this->assertTextPresent("Sound card", "");
+ $this->assertTextPresent("Video card", "");
+ $this->assertTextPresent("Keyboard","");
+ $this->assertTextPresent("Monitor", "");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/DropDownListTestCase.php b/tests/FunctionalTests/quickstart/Controls/DropDownListTestCase.php
index eae8ab36..1b7aca5e 100755
--- a/tests/FunctionalTests/quickstart/Controls/DropDownListTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/DropDownListTestCase.php
@@ -1,65 +1,65 @@
<?php
-class QuickstartDropDownListTestCase extends PradoGenericSeleniumTest
+class QuickstartDropDownListTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TDropDownList.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TDropDownList.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// dropdown list with default settings
- $this->verifyElementPresent("ctl0\$body\$ctl0");
+ $this->assertElementPresent("ctl0\$body\$ctl0");
// dropdown list with initial options
- $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl1"), array('item 1', 'item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl1"), array('item 1', 'item 2', 'item 3', 'item 4'));
$this->assertSelected("ctl0\$body\$ctl1","item 2");
// dropdown list with customized styles
- $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl2"), array('item 1', 'item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl2"), array('item 1', 'item 2', 'item 3', 'item 4'));
$this->assertSelected("ctl0\$body\$ctl2","item 2");
// a disabled dropdown list
$this->verifyAttribute("ctl0\$body\$ctl3@disabled","regexp:true|disabled");
// an auto postback dropdown list
- $this->verifyTextNotPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
+ $this->assertTextNotPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
$this->selectAndWait("ctl0\$body\$ctl4", "label=item 3");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
// a single selection list box upon postback
$this->select("ctl0\$body\$DropDownList1", "label=item 4");
- $this->verifyTextNotPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
+ $this->assertTextNotPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyTextPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
+ $this->assertTextPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
// Databind to an integer-indexed array
$this->selectAndWait("ctl0\$body\$DBDropDownList1", "label=item 3");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: 2, Text: item 3)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 2, Text: item 3)", "");
// Databind to an associative array
$this->selectAndWait("ctl0\$body\$DBDropDownList2", "label=item 2");
- $this->verifyTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
// Databind with DataTextField and DataValueField specified
$this->selectAndWait("ctl0\$body\$DBDropDownList3", "label=Cary");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
// dropdown list is being validated
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
$this->click("id=ctl0_body_ctl7", "");
- $this->verifyVisible('ctl0_body_ctl6');
+ $this->assertVisible('ctl0_body_ctl6');
$this->select("ctl0\$body\$VDropDownList1", "label=item 2");
$this->clickAndWait("id=ctl0_body_ctl7", "");
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
// dropdown list causing validation
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
$this->select("ctl0\$body\$VDropDownList2", "label=Disagree");
$this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl8');
+ $this->assertVisible('ctl0_body_ctl8');
$this->type("ctl0\$body\$TextBox", "test");
$this->selectAndWait("ctl0\$body\$VDropDownList2", "label=Agree");
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/ExpressionTestCase.php b/tests/FunctionalTests/quickstart/Controls/ExpressionTestCase.php
index 4d47fecd..7421bdf6 100755
--- a/tests/FunctionalTests/quickstart/Controls/ExpressionTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/ExpressionTestCase.php
@@ -1,13 +1,13 @@
<?php
-class QuickstartExpressionTestCase extends PradoGenericSeleniumTest
+class QuickstartExpressionTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TExpression.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TExpression.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
- $this->verifyTextPresent('PRADO QuickStart Sample');
+ $this->assertTextPresent('PRADO QuickStart Sample');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/HtmlAreaTestCase.php b/tests/FunctionalTests/quickstart/Controls/HtmlAreaTestCase.php
index caa7a893..3d7de705 100755
--- a/tests/FunctionalTests/quickstart/Controls/HtmlAreaTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/HtmlAreaTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartHtmlAreaTestCase extends PradoGenericSeleniumTest
+class QuickstartHtmlAreaTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.THtmlArea.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.THtmlArea.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
diff --git a/tests/FunctionalTests/quickstart/Controls/HyperLinkTestCase.php b/tests/FunctionalTests/quickstart/Controls/HyperLinkTestCase.php
index dc0261e7..3c80254f 100755
--- a/tests/FunctionalTests/quickstart/Controls/HyperLinkTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/HyperLinkTestCase.php
@@ -1,15 +1,15 @@
<?php
-class QuickstartHyperLinkTestCase extends PradoGenericSeleniumTest
+class QuickstartHyperLinkTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.THyperLink.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.THyperLink.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
- $this->verifyElementPresent("//a[@href=\"http://www.pradosoft.com/\" and @target=\"_blank\"]");
- $this->verifyTextPresent("Welcome to", "");
- $this->verifyTextPresent("Body contents", "");
- $this->verifyElementPresent("//a[img/@alt='Hello World']");
- $this->verifyElementPresent("//a[contains(text(),'Body contents')]");
+ $this->assertElementPresent("//a[@href=\"http://www.pradosoft.com/\" and @target=\"_blank\"]");
+ $this->assertTextPresent("Welcome to", "");
+ $this->assertTextPresent("Body contents", "");
+ $this->assertElementPresent("//a[img/@alt='Hello World']");
+ $this->assertElementPresent("//a[contains(text(),'Body contents')]");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/ImageButtonTestCase.php b/tests/FunctionalTests/quickstart/Controls/ImageButtonTestCase.php
index bf531d72..4133bcbd 100755
--- a/tests/FunctionalTests/quickstart/Controls/ImageButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/ImageButtonTestCase.php
@@ -1,28 +1,28 @@
<?php
-class QuickstartImageButtonTestCase extends PradoGenericSeleniumTest
+class QuickstartImageButtonTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TImageButton.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TImageButton.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// a click button
$this->clickAndWait("//input[@type='image' and @alt='hello world']", "");
- $this->verifyTextPresent("You clicked at ","");
+ $this->assertTextPresent("You clicked at ","");
// a command button
$this->clickAndWait("ctl0\$body\$ctl1", "");
- $this->verifyTextPresent("Command name: test, Command parameter: value","");
+ $this->assertTextPresent("Command name: test, Command parameter: value","");
// a button causing validation
- $this->verifyNotVisible('ctl0_body_ctl2');
+ $this->assertNotVisible('ctl0_body_ctl2');
$this->click("id=ctl0_body_ctl3", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl2');
+ $this->assertVisible('ctl0_body_ctl2');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("id=ctl0_body_ctl3", "");
- $this->verifyNotVisible('ctl0_body_ctl2');
+ $this->assertNotVisible('ctl0_body_ctl2');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/ImageTestCase.php b/tests/FunctionalTests/quickstart/Controls/ImageTestCase.php
index 19e80470..8dcf7d9a 100755
--- a/tests/FunctionalTests/quickstart/Controls/ImageTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/ImageTestCase.php
@@ -1,18 +1,18 @@
<?php
//New Test
-class QuickstartImageTestCase extends PradoGenericSeleniumTest
+class QuickstartImageTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TImage.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TImage.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
- //$this->verifyElementPresent("//img[contains(@src,'/hello_world.gif') and @alt='']");
- $this->verifyElementPresent("//img[contains(@src,'/hello_world.gif') and @alt='Hello World!']");
- $this->verifyTextPresent("Hello World! Hello World! Hello World!", "");
- //$this->verifyElementPresent("//img[contains(@src,'/hello_world.gif') and @align='baseline']");
- //$this->verifyElementPresent("//img[contains(@src,'/hello_world.gif') and contains(@longdesc,'HelloWorld.html')]");
+ //$this->assertElementPresent("//img[contains(@src,'/hello_world.gif') and @alt='']");
+ $this->assertElementPresent("//img[contains(@src,'/hello_world.gif') and @alt='Hello World!']");
+ $this->assertTextPresent("Hello World! Hello World! Hello World!", "");
+ //$this->assertElementPresent("//img[contains(@src,'/hello_world.gif') and @align='baseline']");
+ //$this->assertElementPresent("//img[contains(@src,'/hello_world.gif') and contains(@longdesc,'HelloWorld.html')]");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/LabelTestCase.php b/tests/FunctionalTests/quickstart/Controls/LabelTestCase.php
index 03bba8ed..96873c00 100755
--- a/tests/FunctionalTests/quickstart/Controls/LabelTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/LabelTestCase.php
@@ -1,16 +1,16 @@
<?php
//New Test
-class QuickstartLabelTestCase extends PradoGenericSeleniumTest
+class QuickstartLabelTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TLabel.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TLabel.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
- $this->verifyTextPresent("This is a label with customized color and font.", "");
- $this->verifyTextPresent("This is a form label associated with the TTextBox control below", "");
- $this->verifyTextPresent("This is a label with empty Text property and nonempty body", "");
- $this->verifyTextPresent("This is a disabled label", "");
+ $this->assertTextPresent("This is a label with customized color and font.", "");
+ $this->assertTextPresent("This is a form label associated with the TTextBox control below", "");
+ $this->assertTextPresent("This is a label with empty Text property and <b>nonempty body</b>", "");
+ $this->assertTextPresent("This is a disabled label", "");
$this->verifyAttribute("ctl0_body_Label2@disabled","regexp:true|disabled");
diff --git a/tests/FunctionalTests/quickstart/Controls/LinkButtonTestCase.php b/tests/FunctionalTests/quickstart/Controls/LinkButtonTestCase.php
index 57e7b975..65fd23fb 100755
--- a/tests/FunctionalTests/quickstart/Controls/LinkButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/LinkButtonTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartLinkButtonTestCase extends PradoGenericSeleniumTest
+class QuickstartLinkButtonTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TLinkButton.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TLinkButton.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -21,12 +21,12 @@ class QuickstartLinkButtonTestCase extends PradoGenericSeleniumTest
$this->clickAndWait("//a[contains(text(),'Name: test, Param: value')]", "");
// a button causing validation
- $this->verifyNotVisible('ctl0_body_ctl4');
+ $this->assertNotVisible('ctl0_body_ctl4');
$this->click("link=submit", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl4');
+ $this->assertVisible('ctl0_body_ctl4');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("link=submit", "");
- $this->verifyNotVisible('ctl0_body_ctl4');
+ $this->assertNotVisible('ctl0_body_ctl4');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/ListBoxTestCase.php b/tests/FunctionalTests/quickstart/Controls/ListBoxTestCase.php
index 1cae0d43..99bb0509 100755
--- a/tests/FunctionalTests/quickstart/Controls/ListBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/ListBoxTestCase.php
@@ -1,37 +1,37 @@
<?php
//New Test
-class QuickstartListBoxTestCase extends PradoGenericSeleniumTest
+class QuickstartListBoxTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TListBox.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TListBox.Home&amp;notheme=true&amp;lang=en");
// a default single selection listbox
$this->verifyAttribute("ctl0\$body\$ctl0@size","4");
// single selection list box with initial options
- $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl1"), array('item 1', 'item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl1"), array('item 1', 'item 2', 'item 3', 'item 4'));
$this->assertSelected("ctl0\$body\$ctl1","item 2");
// a single selection list box with customized style
$this->verifyAttribute("ctl0\$body\$ctl2@size","3");
- $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl2"), array('item 1', 'item 2', 'item 3', 'item 4'));
+ $this->assertEquals($this->getSelectOptions("ctl0\$body\$ctl2"), array('item 1', 'item 2', 'item 3', 'item 4'));
$this->assertSelected("ctl0\$body\$ctl2","item 2");
// a disabled list box
$this->verifyAttribute("ctl0\$body\$ctl3@disabled","regexp:true|disabled");
// an auto postback single selection list box
- $this->verifyTextNotPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
+ $this->assertTextNotPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
$this->selectAndWait("ctl0\$body\$ctl4", "label=item 3");
- $this->verifyTextPresent("exact:Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
// a single selection list box upon postback
$this->select("ctl0\$body\$ListBox1", "label=item 4");
- $this->verifyTextNotPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
+ $this->assertTextNotPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyTextPresent("exact:Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
+ $this->assertTextPresent("Your selection is: (Index: 3, Value: value 4, Text: item 4)", "");
// a multiple selection list box
$this->verifyAttribute("ctl0\$body\$ctl6[]@size","4");
@@ -44,39 +44,38 @@ class QuickstartListBoxTestCase extends PradoGenericSeleniumTest
// multiselection list box's behavior upon postback
$this->addSelection("ctl0\$body\$ListBox2[]", "label=item 3");
$this->clickAndWait("name=ctl0\$body\$ctl8", "");
- $this->verifyText("ctl0_body_MultiSelectionResult2","exact:Your selection is: (Index: 1, Value: value 2, Text: item 2)(Index: 2, Value: value 3, Text: item 3)(Index: 3, Value: value 4, Text: item 4)");
+ $this->assertText("ctl0_body_MultiSelectionResult2","Your selection is: (Index: 1, Value: value 2, Text: item 2)(Index: 2, Value: value 3, Text: item 3)(Index: 3, Value: value 4, Text: item 4)");
// Auto postback multiselection list box
$this->addSelection("ctl0\$body\$ctl9[]", "label=item 1");
- $this->waitForPageToLoad(1000);
- $this->verifyText("ctl0_body_MultiSelectionResult","exact:Your selection is: (Index: 0, Value: value 1, Text: item 1)(Index: 1, Value: value 2, Text: item 2)(Index: 3, Value: value 4, Text: item 4)");
+ $this->assertText("ctl0_body_MultiSelectionResult","Your selection is: (Index: 0, Value: value 1, Text: item 1)(Index: 1, Value: value 2, Text: item 2)(Index: 3, Value: value 4, Text: item 4)");
// Databind to an integer-indexed array
$this->selectAndWait("ctl0\$body\$DBListBox1[]", "label=item 3");
- $this->verifyTextPresent("exact:Your selection is: (Index: 2, Value: 2, Text: item 3)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 2, Text: item 3)", "");
// Databind to an associative array
$this->selectAndWait("ctl0\$body\$DBListBox2[]", "label=item 2");
- $this->verifyTextPresent("exact:Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
// Databind with DataTextField and DataValueField specified
$this->selectAndWait("ctl0\$body\$DBListBox3[]", "label=Cary");
- $this->verifyTextPresent("exact:Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
// List box is being validated
- $this->verifyNotVisible('ctl0_body_ctl10');
+ $this->assertNotVisible('ctl0_body_ctl10');
$this->click("id=ctl0_body_ctl11", "");
- $this->verifyVisible('ctl0_body_ctl10');
+ $this->assertVisible('ctl0_body_ctl10');
$this->select("ctl0\$body\$VListBox1", "label=item 2");
$this->clickAndWait("id=ctl0_body_ctl11", "");
- $this->verifyNotVisible('ctl0_body_ctl10');
+ $this->assertNotVisible('ctl0_body_ctl10');
// List box causing validation
- $this->verifyNotVisible('ctl0_body_ctl12');
+ $this->assertNotVisible('ctl0_body_ctl12');
$this->select("ctl0\$body\$VListBox2", "label=Agree");
- $this->verifyVisible('ctl0_body_ctl12');
+ $this->assertVisible('ctl0_body_ctl12');
$this->type("ctl0\$body\$TextBox", "test");
$this->selectAndWait("ctl0\$body\$VListBox2", "label=Disagree");
- $this->verifyNotVisible('ctl0_body_ctl12');
+ $this->assertNotVisible('ctl0_body_ctl12');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php b/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
index 2b47456e..43e0ed8d 100755
--- a/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/MultiViewTestCase.php
@@ -1,34 +1,34 @@
<?php
-class QuickstartMultiViewTestCase extends PradoGenericSeleniumTest
+class QuickstartMultiViewTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TMultiView.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TMultiView.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// view 1 : type in a string
- $this->verifyElementNotPresent('ctl0_body_Result1');
- $this->verifyElementNotPresent('ctl0_body_Result2');
+ $this->assertElementNotPresent('ctl0_body_Result1');
+ $this->assertElementNotPresent('ctl0_body_Result2');
$this->type('ctl0_body_Memo','test');
$this->clickAndWait('ctl0$body$ctl0'); // view 2 to select the dropdown
$this->clickAndWait('ctl0$body$ctl4');
// view 3 : check if the output is updated
- $this->verifyTextPresent('Your text input is: test');
- $this->verifyTextPresent('Your color choice is: Red');
+ $this->assertTextPresent('Your text input is: test');
+ $this->assertTextPresent('Your color choice is: Red');
$this->clickAndWait('ctl0$body$ctl7');
// view 2 : update dropdownlist
- $this->verifyElementNotPresent('ctl0_body_Result1');
- $this->verifyElementNotPresent('ctl0_body_Result2');
+ $this->assertElementNotPresent('ctl0_body_Result1');
+ $this->assertElementNotPresent('ctl0_body_Result2');
$this->select('ctl0$body$DropDownList', "label=Blue");
$this->clickAndWait('ctl0$body$ctl4');
// view 3 : check if the output is updated
- $this->verifyTextPresent('Your text input is: test');
- $this->verifyTextPresent('Your color choice is: Blue');
+ $this->assertTextPresent('Your text input is: test');
+ $this->assertTextPresent('Your color choice is: Blue');
$this->clickAndWait('ctl0$body$ctl7');
// view 2 : check if dropdownlist maintains state
diff --git a/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php b/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
index a1fefed6..ecbfe82d 100755
--- a/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/PagerTestCase.php
@@ -1,56 +1,56 @@
<?php
-class QuickstartPagerTestCase extends PradoGenericSeleniumTest
+class QuickstartPagerTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TPager.Sample1&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TPager.Sample1&amp;notheme=true&amp;lang=en");
// verify datalist content
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextNotPresent('ITN003','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextNotPresent('ITN003','');
// verify numeric paging
$this->clickAndWait("ctl0_body_Pager_ctl1", ""); // 2nd page
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextNotPresent('ITN002','');
- $this->verifyTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextNotPresent('ITN002','');
+ $this->assertTextNotPresent('ITN005','');
$this->clickAndWait("ctl0_body_Pager_ctl3", ""); // 4rd page
- $this->verifyTextPresent('ITN007','');
- $this->verifyTextPresent('ITN008','');
- $this->verifyTextNotPresent('ITN006','');
- $this->verifyTextNotPresent('ITN009','');
+ $this->assertTextPresent('ITN007','');
+ $this->assertTextPresent('ITN008','');
+ $this->assertTextNotPresent('ITN006','');
+ $this->assertTextNotPresent('ITN009','');
$this->clickAndWait("ctl0_body_Pager_ctl6", ""); // last page
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextNotPresent('ITN018','');
- $this->verifyTextNotPresent('ITN001','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextNotPresent('ITN018','');
+ $this->assertTextNotPresent('ITN001','');
// verify next-prev paging
$this->clickAndWait("ctl0_body_Pager2_ctl1", ""); // prev page
- $this->verifyTextPresent('ITN017','');
- $this->verifyTextPresent('ITN018','');
- $this->verifyTextNotPresent('ITN019','');
- $this->verifyTextNotPresent('ITN016','');
+ $this->assertTextPresent('ITN017','');
+ $this->assertTextPresent('ITN018','');
+ $this->assertTextNotPresent('ITN019','');
+ $this->assertTextNotPresent('ITN016','');
$this->clickAndWait("ctl0_body_Pager2_ctl0", ""); // first page
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('ITN002','');
- $this->verifyTextNotPresent('ITN003','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('ITN002','');
+ $this->assertTextNotPresent('ITN003','');
$this->clickAndWait("ctl0_body_Pager2_ctl2", ""); // next page
- $this->verifyTextPresent('ITN003','');
- $this->verifyTextPresent('ITN004','');
- $this->verifyTextNotPresent('ITN002','');
- $this->verifyTextNotPresent('ITN005','');
+ $this->assertTextPresent('ITN003','');
+ $this->assertTextPresent('ITN004','');
+ $this->assertTextNotPresent('ITN002','');
+ $this->assertTextNotPresent('ITN005','');
$this->assertSelected("ctl0_body_Pager3_ctl0","2");
$this->selectAndWait("ctl0_body_Pager3_ctl0", "label=5");
- $this->verifyTextPresent('ITN009','');
- $this->verifyTextPresent('ITN010','');
- $this->verifyTextNotPresent('ITN008','');
- $this->verifyTextNotPresent('ITN011','');
+ $this->assertTextPresent('ITN009','');
+ $this->assertTextPresent('ITN010','');
+ $this->assertTextNotPresent('ITN008','');
+ $this->assertTextNotPresent('ITN011','');
$this->selectAndWait("ctl0_body_Pager3_ctl0", "label=10");
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextNotPresent('ITN018','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextNotPresent('ITN018','');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/PanelTestCase.php b/tests/FunctionalTests/quickstart/Controls/PanelTestCase.php
index 3def308b..1360ec2f 100755
--- a/tests/FunctionalTests/quickstart/Controls/PanelTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/PanelTestCase.php
@@ -1,16 +1,16 @@
<?php
-class QuickstartPanelTestCase extends PradoGenericSeleniumTest
+class QuickstartPanelTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TPanel.Home&amp;notheme=true&amp;lang=en", "");
- $this->verifyTextPresent("This is panel content with", "");
- $this->verifyElementPresent("//span[text()='label']");
- $this->verifyTextPresent("grouping text", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TPanel.Home&amp;notheme=true&amp;lang=en");
+ $this->assertTextPresent("This is panel content with", "");
+ $this->assertElementPresent("//span[text()='label']");
+ $this->assertTextPresent("grouping text", "");
$this->click("//input[@name='ctl0\$body\$ctl17']", "");
- $this->verifyTextNotPresent("You have clicked on 'button2'.");
+ $this->assertTextNotPresent("You have clicked on 'button2'.");
$this->clickAndWait("//input[@type='submit' and @value='button2']", "");
- $this->verifyTextPresent("You have clicked on 'button2'.");
+ $this->assertTextPresent("You have clicked on 'button2'.");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/RadioButtonListTestCase.php b/tests/FunctionalTests/quickstart/Controls/RadioButtonListTestCase.php
index 659f20ff..a9092225 100755
--- a/tests/FunctionalTests/quickstart/Controls/RadioButtonListTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/RadioButtonListTestCase.php
@@ -1,11 +1,11 @@
<?php
//New Test
-class QuickstartRadioButtonListTestCase extends PradoGenericSeleniumTest
+class QuickstartRadioButtonListTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TRadioButtonList.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TRadioButtonList.Home&amp;notheme=true&amp;lang=en");
// RadioButton list with default settings:
$this->click("//input[@name='ctl0\$body\$ctl0' and @value='value 3']", "");
@@ -22,31 +22,31 @@ class QuickstartRadioButtonListTestCase extends PradoGenericSeleniumTest
// RadioButton list's behavior upon postback
$this->click("//input[@name='ctl0\$body\$RadioButtonList' and @value='value 3']", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: value 3, Text: item 3)", "");
// Auto postback check box list
$this->clickAndWait("//input[@name='ctl0\$body\$ctl7' and @value='value 5']", "");
- $this->verifyTextPresent("Your selection is: (Index: 4, Value: value 5, Text: item 5)", "");
+ $this->assertTextPresent("Your selection is: (Index: 4, Value: value 5, Text: item 5)", "");
// Databind to an integer-indexed array
$this->clickAndWait("//input[@name='ctl0\$body\$DBRadioButtonList1' and @value='0']", "");
- $this->verifyTextPresent("Your selection is: (Index: 0, Value: 0, Text: item 1)", "");
+ $this->assertTextPresent("Your selection is: (Index: 0, Value: 0, Text: item 1)", "");
// Databind to an associative array:
$this->clickAndWait("//input[@name='ctl0\$body\$DBRadioButtonList2' and @value='key 2']", "");
- $this->verifyTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
+ $this->assertTextPresent("Your selection is: (Index: 1, Value: key 2, Text: item 2)", "");
// Databind with DataTextField and DataValueField specified
$this->clickAndWait("//input[@name='ctl0\$body\$DBRadioButtonList3' and @value='003']", "");
- $this->verifyTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
+ $this->assertTextPresent("Your selection is: (Index: 2, Value: 003, Text: Cary)", "");
// RadioButton list causing validation
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
$this->click("//input[@name='ctl0\$body\$ctl9' and @value='Agree']", "");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl8');
+ $this->assertVisible('ctl0_body_ctl8');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl9' and @value='Disagree']", "");
- $this->verifyNotVisible('ctl0_body_ctl8');
+ $this->assertNotVisible('ctl0_body_ctl8');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php b/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
index 22031235..da58ce3a 100755
--- a/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/RadioButtonTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartRadioButtonTestCase extends PradoGenericSeleniumTest
+class QuickstartRadioButtonTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TRadioButton.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TRadioButton.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -15,42 +15,42 @@ class QuickstartRadioButtonTestCase extends PradoGenericSeleniumTest
$this->click("//input[@name='ctl0\$body\$ctl1' and @value='value']", "");
// an auto postback radiobutton
- $this->verifyTextNotPresent("I'm clicked");
+ $this->assertTextNotPresent("I'm clicked");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl2' and @value='ctl0\$body\$ctl2']", "");
- $this->verifyTextPresent("I'm clicked");
+ $this->assertTextPresent("I'm clicked");
$this->click("//input[@name='ctl0\$body\$ctl2' and @value='ctl0\$body\$ctl2']", "");
- $this->verifyTextPresent("I'm clicked");
+ $this->assertTextPresent("I'm clicked");
// a radiobutton causing validation on a textbox
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
$this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->click("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
$this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl3');
+ $this->assertVisible('ctl0_body_ctl3');
$this->type("ctl0\$body\$TextBox", "test");
$this->clickAndWait("//input[@name='ctl0\$body\$ctl4' and @value='ctl0\$body\$ctl4']", "");
- $this->verifyNotVisible('ctl0_body_ctl3');
+ $this->assertNotVisible('ctl0_body_ctl3');
// a radiobutton validated by a required field validator
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
$this->click("//input[@type='submit' and @value='Submit']", "");
$this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl6');
+ $this->assertVisible('ctl0_body_ctl6');
$this->click("//input[@name='ctl0\$body\$RadioButton' and @value='ctl0\$body\$RadioButton']", "");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyNotVisible('ctl0_body_ctl6');
+ $this->assertNotVisible('ctl0_body_ctl6');
// a radiobutton group
$this->clickAndWait("name=ctl0\$body\$ctl7", "");
- $this->verifyTextPresent("Your selection is empty");
+ $this->assertTextPresent("Your selection is empty");
$this->click("//input[@name='ctl0\$body\$RadioGroup' and @value='ctl0\$body\$Radio2']", "");
$this->clickAndWait("name=ctl0\$body\$ctl7", "");
- $this->verifyTextPresent("Your selection is 2");
+ $this->assertTextPresent("Your selection is 2");
$this->click("//input[@name='ctl0\$body\$RadioGroup' and @value='ctl0\$body\$Radio3']", "");
$this->click("//input[@name='ctl0\$body\$Radio4' and @value='ctl0\$body\$Radio4']", "");
$this->clickAndWait("name=ctl0\$body\$ctl7", "");
- $this->verifyTextPresent("Your selection is 34");
+ $this->assertTextPresent("Your selection is 34");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Repeater1TestCase.php b/tests/FunctionalTests/quickstart/Controls/Repeater1TestCase.php
index 948055e1..983e3b65 100755
--- a/tests/FunctionalTests/quickstart/Controls/Repeater1TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Repeater1TestCase.php
@@ -1,27 +1,27 @@
<?php
-class QuickstartRepeater1TestCase extends PradoGenericSeleniumTest
+class QuickstartRepeater1TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample1&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample1&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('ID','');
- $this->verifyTextPresent('Name','');
- $this->verifyTextPresent('Quantity','');
- $this->verifyTextPresent('Price','');
- $this->verifyTextPresent('Imported','');
- $this->verifyTextPresent('ITN001','');
- $this->verifyTextPresent('Motherboard','');
- $this->verifyTextPresent('Yes','');
- $this->verifyTextPresent('ITN019','');
- $this->verifyTextPresent('Speaker','');
- $this->verifyTextPresent('No','');
- $this->verifyTextPresent('Computer Parts Inventory','');
+ $this->assertTextPresent('ID','');
+ $this->assertTextPresent('Name','');
+ $this->assertTextPresent('Quantity','');
+ $this->assertTextPresent('Price','');
+ $this->assertTextPresent('Imported','');
+ $this->assertTextPresent('ITN001','');
+ $this->assertTextPresent('Motherboard','');
+ $this->assertTextPresent('Yes','');
+ $this->assertTextPresent('ITN019','');
+ $this->assertTextPresent('Speaker','');
+ $this->assertTextPresent('No','');
+ $this->assertTextPresent('Computer Parts Inventory','');
// verify specific table tags
- $this->verifyElementPresent("//td[@colspan='5']");
- $this->verifyElementPresent("//table[@cellpadding='2']");
+ $this->assertElementPresent("//td[@colspan='5']");
+ $this->assertElementPresent("//table[@cellpadding='2']");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Repeater2TestCase.php b/tests/FunctionalTests/quickstart/Controls/Repeater2TestCase.php
index 7d989fd0..a36af297 100755
--- a/tests/FunctionalTests/quickstart/Controls/Repeater2TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Repeater2TestCase.php
@@ -1,35 +1,35 @@
<?php
-class QuickstartRepeater2TestCase extends PradoGenericSeleniumTest
+class QuickstartRepeater2TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample2&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample2&amp;notheme=true&amp;lang=en");
// verify if all required texts are present
- $this->verifyTextPresent('North','');
- $this->verifyTextPresent('John','');
- $this->verifyTextPresent('Developer','');
- $this->verifyTextPresent('South','');
- $this->verifyTextPresent('Carter','');
- $this->verifyTextPresent('Program Manager','');
+ $this->assertTextPresent('North','');
+ $this->assertTextPresent('John','');
+ $this->assertTextPresent('Developer','');
+ $this->assertTextPresent('South','');
+ $this->assertTextPresent('Carter','');
+ $this->assertTextPresent('Program Manager','');
// verify specific table tags
- $this->verifyElementPresent("//table[@cellspacing='1']");
- $this->verifyElementPresent("//td[@id='ctl0_body_Repeater_ctl1_Cell' and contains(text(),'North')]","");
- $this->verifyElementPresent("//td[@id='ctl0_body_Repeater_ctl1_Cell']","");
- $this->verifyElementPresent("//td[@id='ctl0_body_Repeater_ctl2_Cell']","");
- $this->verifyElementPresent("//td[@id='ctl0_body_Repeater_ctl3_Cell']","");
- $this->verifyElementPresent("//td[@id='ctl0_body_Repeater_ctl4_Cell']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl1_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl2_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl3_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl1_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl2_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl3_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl3_Repeater2_ctl1_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl3_Repeater2_ctl2_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl4_Repeater2_ctl1_Row']","");
- $this->verifyElementPresent("//tr[@id='ctl0_body_Repeater_ctl4_Repeater2_ctl2_Row']","");
+ $this->assertElementPresent("//table[@cellspacing='1']");
+ $this->assertElementPresent("//td[@id='ctl0_body_Repeater_ctl1_Cell' and contains(text(),'North')]","");
+ $this->assertElementPresent("//td[@id='ctl0_body_Repeater_ctl1_Cell']","");
+ $this->assertElementPresent("//td[@id='ctl0_body_Repeater_ctl2_Cell']","");
+ $this->assertElementPresent("//td[@id='ctl0_body_Repeater_ctl3_Cell']","");
+ $this->assertElementPresent("//td[@id='ctl0_body_Repeater_ctl4_Cell']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl1_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl2_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl1_Repeater2_ctl3_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl1_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl2_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl2_Repeater2_ctl3_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl3_Repeater2_ctl1_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl3_Repeater2_ctl2_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl4_Repeater2_ctl1_Row']","");
+ $this->assertElementPresent("//tr[@id='ctl0_body_Repeater_ctl4_Repeater2_ctl2_Row']","");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Repeater3TestCase.php b/tests/FunctionalTests/quickstart/Controls/Repeater3TestCase.php
index a5031af5..22a5ab71 100755
--- a/tests/FunctionalTests/quickstart/Controls/Repeater3TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Repeater3TestCase.php
@@ -1,22 +1,22 @@
<?php
-class QuickstartRepeater3TestCase extends PradoGenericSeleniumTest
+class QuickstartRepeater3TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample3&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TRepeater.Sample3&amp;notheme=true&amp;lang=en");
// verify product name is required
- $this->verifyNotVisible('ctl0_body_Repeater_ctl0_ctl0');
+ $this->assertNotVisible('ctl0_body_Repeater_ctl0_ctl0');
$this->type("ctl0_body_Repeater_ctl0_ProductName", "");
$this->click("//input[@type='submit' and @value='Save']", "");
- $this->verifyVisible('ctl0_body_Repeater_ctl0_ctl0');
+ $this->assertVisible('ctl0_body_Repeater_ctl0_ctl0');
// verify product price is of proper format
- $this->verifyNotVisible('ctl0_body_Repeater_ctl0_ctl1');
+ $this->assertNotVisible('ctl0_body_Repeater_ctl0_ctl1');
$this->type("ctl0_body_Repeater_ctl0_ProductPrice", "abc");
$this->click("//input[@type='submit' and @value='Save']", "");
- $this->verifyVisible('ctl0_body_Repeater_ctl0_ctl1');
+ $this->assertVisible('ctl0_body_Repeater_ctl0_ctl1');
// perform postback
$this->click("ctl0_body_Repeater_ctl0_ProductImported",'');
@@ -24,12 +24,12 @@ class QuickstartRepeater3TestCase extends PradoGenericSeleniumTest
$this->type("ctl0_body_Repeater_ctl0_ProductPrice", "99.01");
$this->select("ctl0_body_Repeater_ctl3_ProductCategory", "label=Accessories");
$this->clickAndWait("//input[@type='submit' and @value='Save']", "");
- $this->verifyNotVisible('ctl0_body_Repeater_ctl0_ctl0');
- $this->verifyNotVisible('ctl0_body_Repeater_ctl0_ctl1');
+ $this->assertNotVisible('ctl0_body_Repeater_ctl0_ctl0');
+ $this->assertNotVisible('ctl0_body_Repeater_ctl0_ctl1');
// verify postback results
- $this->verifyElementPresent("//td[text()='Mother Board']",'');
- $this->verifyElementNotPresent("//td[text()='Input Devices']",'');
- $this->verifyElementPresent("//td[text()='99.01']",'');
+ $this->assertElementPresent("//td[text()='Mother Board']",'');
+ $this->assertElementNotPresent("//td[text()='Input Devices']",'');
+ $this->assertElementPresent("//td[text()='99.01']",'');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/StatementsTestCase.php b/tests/FunctionalTests/quickstart/Controls/StatementsTestCase.php
index a7c4c579..4085b005 100755
--- a/tests/FunctionalTests/quickstart/Controls/StatementsTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/StatementsTestCase.php
@@ -1,13 +1,13 @@
<?php
-class QuickstartStatementsTestCase extends PradoGenericSeleniumTest
+class QuickstartStatementsTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TStatements.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TStatements.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
- $this->verifyTextPresent('UniqueID is \'ctl0$body$ctl0\'');
+ $this->assertTextPresent('UniqueID is \'ctl0$body$ctl0\'');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/TabPanelTestCase.php b/tests/FunctionalTests/quickstart/Controls/TabPanelTestCase.php
index d01e824d..3dc54ae2 100755
--- a/tests/FunctionalTests/quickstart/Controls/TabPanelTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/TabPanelTestCase.php
@@ -1,47 +1,47 @@
<?php
-class QuickstartTabPanelTestCase extends PradoGenericSeleniumTest
+class QuickstartTabPanelTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TTabPanel.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TTabPanel.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// verify initial visibility
- $this->verifyNotVisible('ctl0_body_View1'); // view 1
- $this->verifyVisible('ctl0_body_View2'); // view 2
- $this->verifyNotVisible('ctl0_body_ctl2'); // view 3
+ $this->assertNotVisible('ctl0_body_View1'); // view 1
+ $this->assertVisible('ctl0_body_View2'); // view 2
+ $this->assertNotVisible('ctl0_body_ctl2'); // view 3
// switching to the first view
$this->click('ctl0_body_View1_0');
$this->pause(500);
- $this->verifyVisible('ctl0_body_View1'); // view 1
- $this->verifyNotVisible('ctl0_body_View2'); // view 2
- $this->verifyNotVisible('ctl0_body_ctl2'); // view 3
- $this->verifyNotVisible('ctl0_body_View11'); // view 11
- $this->verifyVisible('ctl0_body_View21'); // view 21
+ $this->assertVisible('ctl0_body_View1'); // view 1
+ $this->assertNotVisible('ctl0_body_View2'); // view 2
+ $this->assertNotVisible('ctl0_body_ctl2'); // view 3
+ $this->assertNotVisible('ctl0_body_View11'); // view 11
+ $this->assertVisible('ctl0_body_View21'); // view 21
// switching to View11
$this->click('ctl0_body_View11_0');
$this->pause(500);
- $this->verifyVisible('ctl0_body_View1'); // view 1
- $this->verifyNotVisible('ctl0_body_View2'); // view 2
- $this->verifyNotVisible('ctl0_body_ctl2'); // view 3
- $this->verifyVisible('ctl0_body_View11'); // view 11
- $this->verifyNotVisible('ctl0_body_View21'); // view 21
+ $this->assertVisible('ctl0_body_View1'); // view 1
+ $this->assertNotVisible('ctl0_body_View2'); // view 2
+ $this->assertNotVisible('ctl0_body_ctl2'); // view 3
+ $this->assertVisible('ctl0_body_View11'); // view 11
+ $this->assertNotVisible('ctl0_body_View21'); // view 21
// switching to the third view
$this->click('ctl0_body_ctl2_0');
$this->pause(500);
- $this->verifyNotVisible('ctl0_body_View1'); // view 1
- $this->verifyNotVisible('ctl0_body_View2'); // view 2
- $this->verifyVisible('ctl0_body_ctl2'); // view 3
+ $this->assertNotVisible('ctl0_body_View1'); // view 1
+ $this->assertNotVisible('ctl0_body_View2'); // view 2
+ $this->assertVisible('ctl0_body_ctl2'); // view 3
// submit: check if the visibility is kept
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyNotVisible('ctl0_body_View1'); // view 1
- $this->verifyNotVisible('ctl0_body_View2'); // view 2
- $this->verifyVisible('ctl0_body_ctl2'); // view 3
+ $this->assertNotVisible('ctl0_body_View1'); // view 1
+ $this->assertNotVisible('ctl0_body_View2'); // view 2
+ $this->assertVisible('ctl0_body_ctl2'); // view 3
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/TableTestCase.php b/tests/FunctionalTests/quickstart/Controls/TableTestCase.php
index 128f4b22..aafd6f80 100755
--- a/tests/FunctionalTests/quickstart/Controls/TableTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/TableTestCase.php
@@ -1,18 +1,18 @@
<?php
-class QuickstartTableTestCase extends PradoGenericSeleniumTest
+class QuickstartTableTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TTable.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TTable.Home&amp;notheme=true&amp;lang=en");
- $this->verifyElementPresent("//table[@rules='all' and @border='1']");
- $this->verifyElementPresent("//table/caption[@align='bottom' and text()='This is table caption']");
- $this->verifyElementPresent("//th[text()='header cell 2']");
- $this->verifyElementPresent("//tr[@align='right']/td[text()='text']");
- $this->verifyElementPresent("//td[@align='center' and contains(text(),'cell 5')]");
+ $this->assertElementPresent("//table[@rules='all' and @border='1']");
+ $this->assertElementPresent("//table/caption[@align='bottom' and text()='This is table caption']");
+ $this->assertElementPresent("//th[text()='header cell 2']");
+ $this->assertElementPresent("//tr[@align='right']/td[text()='text']");
+ $this->assertElementPresent("//td[@align='center' and contains(text(),'cell 5')]");
- $this->verifyElementPresent("//th[text()='Header 1']");
- $this->verifyElementPresent("//td[text()='Cell 1']");
+ $this->assertElementPresent("//th[text()='Header 1']");
+ $this->assertElementPresent("//td[text()='Cell 1']");
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php b/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
index a3464702..0f512d2c 100755
--- a/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/TextBoxTestCase.php
@@ -1,10 +1,10 @@
<?php
-class QuickstartTextBoxTestCase extends PradoGenericSeleniumTest
+class QuickstartTextBoxTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TTextBox.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TTextBox.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
@@ -29,27 +29,27 @@ class QuickstartTextBoxTestCase extends PradoGenericSeleniumTest
$this->verifyAttribute("ctl0\$body\$ctl5@readonly","regexp:true|readonly");
// auto postback textbox, CausesValidation=false
- $this->verifyValue("ctl0\$body\$ctl6", "change me");
- $this->typeAndWait("ctl0\$body\$ctl6", "change mes");
- $this->verifyValue("ctl0\$body\$ctl6", "text changed");
+ $this->assertValue("ctl0\$body\$ctl6", "change me");
+ $this->type("ctl0\$body\$ctl6", "change mes");
+ $this->assertValue("ctl0\$body\$ctl6", "text changed");
// auto postback textbox, CausesValidation=true
- $this->verifyNotVisible('ctl0_body_ctl7');
+ $this->assertNotVisible('ctl0_body_ctl7');
$this->type("ctl0\$body\$TextBox3", "test");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl7');
- $this->typeAndWait("ctl0\$body\$TextBox3", "non test");
- $this->verifyNotVisible('ctl0_body_ctl7');
+ $this->assertVisible('ctl0_body_ctl7');
+ $this->type("ctl0\$body\$TextBox3", "non test");
+ $this->assertNotVisible('ctl0_body_ctl7');
// submitting textbox with a button
$this->type("ctl0\$body\$TextBox1", "texttext");
$this->clickAndWait("//input[@type='submit' and @value='Submit']", "");
- $this->verifyValue("ctl0\$body\$TextBox1", "You just entered 'texttext'.");
+ $this->assertValue("ctl0\$body\$TextBox1", "You just entered 'texttext'.");
// SafeText
- $this->verifyText("ctl0_body_Output","test");
- $this->typeAndWait("ctl0\$body\$TextBox2","<a href=javascript:xxx>malicious code</a>");
- $this->verifyText("ctl0_body_Output","malicious code");
+ $this->assertText("ctl0_body_Output","test");
+ $this->type("ctl0\$body\$TextBox2","<a href=javascript:xxx>malicious code</a>");
+ $this->assertText("ctl0_body_Output","malicious code");
// password
$this->verifyAttribute("ctl0\$body\$ctl9@type","password");
@@ -71,21 +71,21 @@ End of message
$this->verifyAttribute("ctl0\$body\$ctl13@wrap","off");
// auto postback textbox
- $this->verifyValue("ctl0\$body\$ctl14", "change me");
- $this->typeAndWait("ctl0\$body\$ctl14", "change mes");
- $this->verifyValue("ctl0\$body\$ctl14", "text changed");
- $this->verifyValue("ctl0\$body\$ctl10", "This is a\nmultiline\ntextbox.");
- $this->verifyValue("ctl0\$body\$ctl11", "This is a multiline text box.
+ $this->assertValue("ctl0\$body\$ctl14", "change me");
+ $this->type("ctl0\$body\$ctl14", "change mes");
+ $this->assertValue("ctl0\$body\$ctl14", "text changed");
+ $this->assertValue("ctl0\$body\$ctl10", "This is a\nmultiline\ntextbox.");
+ $this->assertValue("ctl0\$body\$ctl11", "This is a multiline text box.
In HTML, it is displayed as a textarea.
End of message
");
// textbox associated with a validator
- $this->verifyNotVisible('ctl0_body_ctl15');
+ $this->assertNotVisible('ctl0_body_ctl15');
$this->type("ctl0\$body\$MultiTextBox3", "demo");
// $this->pause(1000);
- $this->verifyVisible('ctl0_body_ctl15');
- $this->typeAndWait("ctl0\$body\$MultiTextBox3", "non demo");
- $this->verifyNotVisible('ctl0_body_ctl15');
+ $this->assertVisible('ctl0_body_ctl15');
+ $this->type("ctl0\$body\$MultiTextBox3", "non demo");
+ $this->assertNotVisible('ctl0_body_ctl15');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard1TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard1TestCase.php
index 5e7018c4..49a92fb7 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard1TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard1TestCase.php
@@ -1,24 +1,24 @@
<?php
-class QuickstartWizard1TestCase extends PradoGenericSeleniumTest
+class QuickstartWizard1TestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample1&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample1&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// step 1
- $this->verifyTextPresent('Wizard Step 1');
- $this->verifyTextNotPresent('Wizard Step 2');
- $this->verifyVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
+ $this->assertTextPresent('Wizard Step 1');
+ $this->assertTextNotPresent('Wizard Step 2');
+ $this->assertVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
$this->verifyAttribute('ctl0_body_Wizard1_SideBarList_ctl1_SideBarButton@disabled','regexp:true|disabled');
$this->select('ctl0$body$Wizard1$DropDownList1', "label=Purple");
$this->clickAndWait('ctl0$body$Wizard1$ctl6$ctl1');
// step 2
- $this->verifyTextPresent('Your favorite color is: Purple');
- $this->verifyTextNotPresent('Wizard Step 1');
- $this->verifyTextPresent('Wizard Step 2');
+ $this->assertTextPresent('Your favorite color is: Purple');
+ $this->assertTextNotPresent('Wizard Step 1');
+ $this->assertTextPresent('Wizard Step 2');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard2TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard2TestCase.php
index a77280ff..23881968 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard2TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard2TestCase.php
@@ -1,24 +1,24 @@
<?php
-class QuickstartWizard2TestCase extends PradoGenericSeleniumTest
+class QuickstartWizard2TestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample2&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample2&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// step 1
- $this->verifyTextPresent('Please let us know your preference');
- $this->verifyTextNotPresent('Thank you for your answer');
- $this->verifyVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
+ $this->assertTextPresent('Please let us know your preference');
+ $this->assertTextNotPresent('Thank you for your answer');
+ $this->assertVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
$this->verifyAttribute('ctl0_body_Wizard1_SideBarList_ctl1_SideBarButton@disabled','regexp:true|disabled');
$this->select('ctl0$body$Wizard1$DropDownList1', "label=Blue");
$this->clickAndWait('ctl0$body$Wizard1$ctl6$ctl1');
// step 2
- $this->verifyTextPresent('Your favorite color is: Blue');
- $this->verifyTextNotPresent('Please let us know your preference');
- $this->verifyTextPresent('Thank you for your answer');
+ $this->assertTextPresent('Your favorite color is: Blue');
+ $this->assertTextNotPresent('Please let us know your preference');
+ $this->assertTextPresent('Thank you for your answer');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard3TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard3TestCase.php
index ec0efe90..d58ca4fe 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard3TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard3TestCase.php
@@ -1,16 +1,16 @@
<?php
-class QuickstartWizard3TestCase extends PradoGenericSeleniumTest
+class QuickstartWizard3TestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample3&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample3&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// step 1
- $this->verifyTextPresent('A Mini Survey');
- $this->verifyTextPresent('PRADO QuickStart Sample');
+ $this->assertTextPresent('A Mini Survey');
+ $this->assertTextPresent('PRADO QuickStart Sample');
$this->click('ctl0_body_Wizard3_StudentCheckBox');
$this->clickAndWait('ctl0$body$Wizard3$ctl4$ctl0');
@@ -23,12 +23,12 @@ class QuickstartWizard3TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0$body$Wizard3$ctl6$ctl1');
// step 4
- $this->verifyTextPresent('You are a college student');
- $this->verifyTextPresent('You are in major: Chemistry');
- $this->verifyTextPresent('Your favorite sport is: Tennis');
+ $this->assertTextPresent('You are a college student');
+ $this->assertTextPresent('You are in major: Chemistry');
+ $this->assertTextPresent('Your favorite sport is: Tennis');
// run the example again. this time we skip the page asking about major
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample3&amp;notheme=true", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample3&amp;notheme=true");
// step 1
$this->clickAndWait('ctl0$body$Wizard3$ctl4$ctl0');
@@ -38,7 +38,7 @@ class QuickstartWizard3TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0$body$Wizard3$ctl6$ctl1');
// step 4
- $this->verifyTextNotPresent('You are a college student');
- $this->verifyTextPresent('Your favorite sport is: Baseball');
+ $this->assertTextNotPresent('You are a college student');
+ $this->assertTextPresent('Your favorite sport is: Baseball');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
index f2b8ad6e..fa565abb 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard4TestCase.php
@@ -1,21 +1,21 @@
<?php
-class QuickstartWizard4TestCase extends PradoGenericSeleniumTest
+class QuickstartWizard4TestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample4&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample4&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// step 1
- $this->verifyTextPresent('Step 1 of 3');
+ $this->assertTextPresent('Step 1 of 3');
$this->select('ctl0_body_Wizard1_DropDownList1', "label=Cyan");
$this->clickAndWait('ctl0_body_Wizard1_SideBarList_ctl2_SideBarButton');
// step 3
- $this->verifyTextPresent('Step 3 of 3');
- $this->verifyTextPresent('Thank you for completing this survey.');
+ $this->assertTextPresent('Step 3 of 3');
+ $this->assertTextPresent('Thank you for completing this survey.');
$this->clickAndWait('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
// step 1
@@ -24,12 +24,12 @@ class QuickstartWizard4TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0_body_Wizard1_ctl4_ctl0');
// step 2
- $this->verifyTextPresent('Step 2 of 3');
- $this->verifyTextPresent('Your favorite color is: Black');
+ $this->assertTextPresent('Step 2 of 3');
+ $this->assertTextPresent('Your favorite color is: Black');
$this->clickAndWait('ctl0_body_Wizard1_ctl5_ctl0');
// step 1
- $this->verifyTextPresent('Step 1 of 3');
+ $this->assertTextPresent('Step 1 of 3');
$this->assertSelected('ctl0_body_Wizard1_DropDownList1', "Black");
$this->clickAndWait('ctl0_body_Wizard1_ctl4_ctl0');
@@ -37,6 +37,6 @@ class QuickstartWizard4TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0_body_Wizard1_ctl5_ctl1');
// step 3
- $this->verifyTextPresent('Step 3 of 3');
+ $this->assertTextPresent('Step 3 of 3');
}
}
diff --git a/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php b/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
index eb5edb3b..8fbd59c5 100755
--- a/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
+++ b/tests/FunctionalTests/quickstart/Controls/Wizard5TestCase.php
@@ -1,17 +1,17 @@
<?php
-class QuickstartWizard5TestCase extends PradoGenericSeleniumTest
+class QuickstartWizard5TestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample5&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Controls.Samples.TWizard.Sample5&amp;notheme=true&amp;lang=en");
$this->verifyTitle("PRADO QuickStart Sample", "");
// step 1
- $this->verifyTextPresent('Please let us know your preference');
- $this->verifyVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
- $this->verifyVisible('ctl0_body_Wizard1_SideBarList_ctl1_SideBarButton');
+ $this->assertTextPresent('Please let us know your preference');
+ $this->assertVisible('ctl0_body_Wizard1_SideBarList_ctl0_SideBarButton');
+ $this->assertVisible('ctl0_body_Wizard1_SideBarList_ctl1_SideBarButton');
$this->verifyAttribute('ctl0_body_Wizard1_SideBarList_ctl2_SideBarButton@disabled','regexp:true|disabled');
$this->select('ctl0_body_Wizard1_DropDownList1', "label=Cyan");
$this->clickAndWait('ctl0$body$Wizard1$ctl4$ctl0');
@@ -29,7 +29,7 @@ class QuickstartWizard5TestCase extends PradoGenericSeleniumTest
$this->clickAndWait('ctl0$body$Wizard1$ctl6$ctl1');
// step 3
- $this->verifyTextPresent('Your favorite color is: Cyan');
- $this->verifyTextPresent('Your favorite sport is: Football');
+ $this->assertTextPresent('Your favorite color is: Cyan');
+ $this->assertTextPresent('Your favorite sport is: Football');
}
}
diff --git a/tests/FunctionalTests/quickstart/Fundamentals/HangmanTestCase.php b/tests/FunctionalTests/quickstart/Fundamentals/HangmanTestCase.php
index 3d531b47..7cf34d30 100755
--- a/tests/FunctionalTests/quickstart/Fundamentals/HangmanTestCase.php
+++ b/tests/FunctionalTests/quickstart/Fundamentals/HangmanTestCase.php
@@ -1,32 +1,32 @@
<?php
-class QuickstartHangmanTestCase extends PradoGenericSeleniumTest
+class QuickstartHangmanTestCase extends PradoGenericSelenium2Test
{
function test ()
{
- $this->open("../../demos/quickstart/index.php?page=Fundamentals.Samples.Hangman.Home&amp;notheme=true&amp;lang=en", "");
+ $this->url("../../demos/quickstart/index.php?page=Fundamentals.Samples.Hangman.Home&amp;notheme=true&amp;lang=en");
$this->verifyTitle("Hangman Game", "");
- $this->verifyTextPresent("Medium game; you are allowed 5 misses.", "");
+ $this->assertTextPresent("Medium game; you are allowed 5 misses.", "");
$this->clickAndWait("//input[@type='submit' and @value='Play!']", "");
- $this->verifyTextPresent("You must choose a difficulty level", "");
+ $this->assertTextPresent("You must choose a difficulty level", "");
$this->clickAndWait("//input[@type='submit' and @value='Play!']", "");
$this->click("//input[@name='ctl0\$body\$LevelSelection' and @value='3']", "");
$this->clickAndWait("//input[@type='submit' and @value='Play!']", "");
- $this->verifyTextPresent("Please make a guess", "");
- $this->verifyTextPresent("maximum of 3", "");
+ $this->assertTextPresent("Please make a guess", "");
+ $this->assertTextPresent("maximum of 3", "");
$this->clickAndWait("link=B", "");
$this->clickAndWait("link=F", "");
$this->clickAndWait("link=Give up?", "");
- $this->verifyTextPresent("You Lose", "");
+ $this->assertTextPresent("You Lose", "");
$this->clickAndWait("link=Start Again", "");
$this->clickAndWait("//input[@type='submit' and @value='Play!']", "");
- $this->verifyTextPresent("Please make a guess", "");
- $this->verifyTextPresent("maximum of 3", "");
+ $this->assertTextPresent("Please make a guess", "");
+ $this->assertTextPresent("maximum of 3", "");
$this->clickAndWait("link=Give up?", "");
- $this->verifyTextPresent("You Lose", "");
+ $this->assertTextPresent("You Lose", "");
$this->clickAndWait("link=Start Again", "");
$this->click("//input[@name='ctl0\$body\$LevelSelection' and @value='5']", "");
$this->clickAndWait("//input[@type='submit' and @value='Play!']", "");
- $this->verifyTextPresent("maximum of 5", "");
+ $this->assertTextPresent("maximum of 5", "");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Issue120TestCase.php b/tests/FunctionalTests/tickets/tests/Issue120TestCase.php
index 20a4096b..8587415e 100755
--- a/tests/FunctionalTests/tickets/tests/Issue120TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Issue120TestCase.php
@@ -1,15 +1,15 @@
<?php
-class Issue120TestCase extends PradoGenericSeleniumTest
+class Issue120TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Issue120');
+ $this->url('tickets/index.php?page=Issue120');
$this->assertTextPresent('TActiveDropDownList PromptValue Test');
-
+
$this->assertSelectedIndex("ctl0_Content_ddl1", 0);
$this->assertSelectedValue("ctl0_Content_ddl1", 'PromptValue');
-
+
$this->click("ctl0_Content_btn1");
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Issue216TestCase.php b/tests/FunctionalTests/tickets/tests/Issue216TestCase.php
index 375f90a7..bb1daa6b 100755
--- a/tests/FunctionalTests/tickets/tests/Issue216TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Issue216TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Issue216TestCase extends PradoGenericSeleniumTest
+class Issue216TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Issue216');
+ $this->url('tickets/index.php?page=Issue216');
$this->assertTextPresent('TTabPanel doesn\'t preserve active tab on callback request');
-
+
$this->assertVisible('ctl0_Content_tab1');
$this->click("ctl0_Content_btn1");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket121TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket121TestCase.php
index 905a31a4..3fea580a 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket121TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket121TestCase.php
@@ -1,17 +1,17 @@
<?php
-class Ticket121TestCase extends PradoGenericSeleniumTest
+class Ticket121TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket121');
+ $this->url('tickets/index.php?page=Ticket121');
$this->type("ctl0\$Content\$FooTextBox", "");
- $this->verifyNotVisible('ctl0_Content_ctl1');
+ $this->assertNotVisible('ctl0_Content_ctl1');
$this->click("//input[@type='image' and @id='ctl0_Content_ctl0']", "");
- $this->verifyVisible('ctl0_Content_ctl1');
+ $this->assertVisible('ctl0_Content_ctl1');
$this->type("ctl0\$Content\$FooTextBox", "content");
$this->clickAndWait("//input[@type='image' and @id='ctl0_Content_ctl0']", "");
- $this->verifyNotVisible('ctl0_Content_ctl1');
- $this->verifyTextPresent("clicked at", "");
+ $this->assertNotVisible('ctl0_Content_ctl1');
+ $this->assertTextPresent("clicked at", "");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket163TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket163TestCase.php
index 1727ac40..ffd95d86 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket163TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket163TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket163TestCase extends PradoGenericSeleniumTest
+class Ticket163TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket163');
+ $this->url('tickets/index.php?page=Ticket163');
$this->assertTextPresent('kr 100,00');
$this->assertTextPresent('kr 0,00');
$this->assertTextPresent('-kr 100,00');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket169TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket169TestCase.php
index 9889ea50..a9c006f9 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket169TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket169TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket169TestCase extends PradoGenericSeleniumTest
+class Ticket169TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket169');
+ $this->url('tickets/index.php?page=Ticket169');
$this->assertNotVisible('ctl0_Content_validator1');
$this->click('ctl0_Content_ctl0');
$this->assertVisible('ctl0_Content_validator1');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket191TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket191TestCase.php
index 88de08cc..2b2b1a41 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket191TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket191TestCase.php
@@ -1,14 +1,14 @@
<?php
-class Ticket191TestCase extends PradoGenericSeleniumTest
+class Ticket191TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket191');
+ $this->url('tickets/index.php?page=Ticket191');
$this->type("ctl0\$Content\$TextBox2", "test");
$this->clickAndWait("name=ctl0\$Content\$ctl0");
$this->type("ctl0\$Content\$TextBox", "test");
$this->clickAndWait("name=ctl0\$Content\$ctl1");
- $this->verifyNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl2');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket205TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket205TestCase.php
index 86768354..53761d14 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket205TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket205TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket205TestCase extends PradoGenericSeleniumTest
+class Ticket205TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open("tickets/index.php?page=Ticket205");
- $this->assertTitle("Verifying Ticket 205");
+ $this->url("tickets/index.php?page=Ticket205");
+ $this->assertEquals($this->title(), "Verifying Ticket 205");
$this->assertNotVisible("{$base}validator1");
$this->type("{$base}textbox1", "test");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php
index cd618a5d..f7cbe814 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket207TestCase.php
@@ -1,20 +1,20 @@
<?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->assertVisible("{$base}validator1");
$this->assertVisible("{$base}validator2");
-
+
$this->type("{$base}text1", 'test');
$this->assertVisible("{$base}validator1");
$this->assertVisible("{$base}validator2");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket21TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket21TestCase.php
index 5e48ff2d..7a245111 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket21TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket21TestCase.php
@@ -1,14 +1,14 @@
<?php
-class Ticket21TestCase extends PradoGenericSeleniumTest
+class Ticket21TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket21');
- $this->assertTitle("Verifying Ticket 21");
+ $this->url('tickets/index.php?page=Ticket21');
+ $this->assertEquals($this->title(), "Verifying Ticket 21");
$this->clickAndWait("ctl0_Content_button1");
- $this->verifyTextPresent("Radio button clicks: 1", "");
+ $this->assertTextPresent("Radio button clicks: 1", "");
$this->click("ctl0_Content_button1");
- $this->verifyTextPresent("Radio button clicks: 1", "");
+ $this->assertTextPresent("Radio button clicks: 1", "");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket220TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket220TestCase.php
index 120e7bd0..2e6da431 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket220TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket220TestCase.php
@@ -1,16 +1,16 @@
<?php
-class Ticket220TestCase extends PradoGenericSeleniumTest
+class Ticket220TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket220');
+ $this->url('tickets/index.php?page=Ticket220');
$this->assertTextPresent('ClientScript Test');
$this->assertText("{$base}label1", "Label 1");
$this->click("button1");
- $this->assertText("{$base}label1", 'exact:Label 1: ok; ok 3?; ok 2!');
+ $this->assertText("{$base}label1", 'Label 1: ok; ok 3?; ok 2!');
$this->assertAlertNotPresent();
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket225TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket225TestCase.php
index 3680eea1..d17a9555 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket225TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket225TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket225TestCase extends PradoGenericSeleniumTest
+class Ticket225TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket225');
+ $this->url('tickets/index.php?page=Ticket225');
$this->assertTextPresent('RadioButton Group Tests');
$this->assertText("{$base}label1", "Label 1");
@@ -16,7 +16,7 @@ class Ticket225TestCase extends PradoGenericSeleniumTest
$this->click("{$base}button2");
$this->clickAndWait("{$base}button4");
- $this->assertText("{$base}label1", 'exact:ctl0$Content$button1 ctl0$Content$button2 ctl0$Content$button3');
+ $this->assertText("{$base}label1", 'ctl0$Content$button1 ctl0$Content$button2 ctl0$Content$button3');
$this->assertNotVisible("{$base}validator1");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket227TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket227TestCase.php
index 1f1c0fb9..3defa014 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket227TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket227TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket227TestCase extends PradoGenericSeleniumTest
+class Ticket227TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket227');
- $this->assertTitle('Verifying Ticket 227');
+ $this->url('tickets/index.php?page=Ticket227');
+ $this->assertEquals($this->title(), 'Verifying Ticket 227');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket239TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket239TestCase.php
index 57251d23..6f5f0ed9 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket239TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket239TestCase.php
@@ -1,53 +1,53 @@
<?php
-class Ticket239TestCase extends PradoGenericSeleniumTest
+class Ticket239TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket239');
+ $this->url('tickets/index.php?page=Ticket239');
// view1
- $this->verifyTextPresent('view1 is activated','');
- $this->verifyTextNotPresent('view1 is deactivated','');
- $this->verifyTextNotPresent('view2 is activated','');
- $this->verifyTextNotPresent('view2 is deactivated','');
- $this->verifyTextNotPresent('view3 is activated','');
- $this->verifyTextNotPresent('view3 is deactivated','');
+ $this->assertTextPresent('view1 is activated','');
+ $this->assertTextNotPresent('view1 is deactivated','');
+ $this->assertTextNotPresent('view2 is activated','');
+ $this->assertTextNotPresent('view2 is deactivated','');
+ $this->assertTextNotPresent('view3 is activated','');
+ $this->assertTextNotPresent('view3 is deactivated','');
// goto view2
$this->clickAndWait('name=ctl0$Content$ctl1');
- $this->verifyTextNotPresent('view1 is activated','');
- $this->verifyTextPresent('view1 is deactivated','');
- $this->verifyTextPresent('view2 is activated','');
- $this->verifyTextNotPresent('view2 is deactivated','');
- $this->verifyTextNotPresent('view3 is activated','');
- $this->verifyTextNotPresent('view3 is deactivated','');
+ $this->assertTextNotPresent('view1 is activated','');
+ $this->assertTextPresent('view1 is deactivated','');
+ $this->assertTextPresent('view2 is activated','');
+ $this->assertTextNotPresent('view2 is deactivated','');
+ $this->assertTextNotPresent('view3 is activated','');
+ $this->assertTextNotPresent('view3 is deactivated','');
// goto view3
$this->clickAndWait('name=ctl0$Content$ctl3');
- $this->verifyTextNotPresent('view1 is activated','');
- $this->verifyTextNotPresent('view1 is deactivated','');
- $this->verifyTextNotPresent('view2 is activated','');
- $this->verifyTextPresent('view2 is deactivated','');
- $this->verifyTextPresent('view3 is activated','');
- $this->verifyTextNotPresent('view3 is deactivated','');
+ $this->assertTextNotPresent('view1 is activated','');
+ $this->assertTextNotPresent('view1 is deactivated','');
+ $this->assertTextNotPresent('view2 is activated','');
+ $this->assertTextPresent('view2 is deactivated','');
+ $this->assertTextPresent('view3 is activated','');
+ $this->assertTextNotPresent('view3 is deactivated','');
// goto view2
$this->clickAndWait('name=ctl0$Content$ctl4');
- $this->verifyTextNotPresent('view1 is activated','');
- $this->verifyTextNotPresent('view1 is deactivated','');
- $this->verifyTextPresent('view2 is activated','');
- $this->verifyTextNotPresent('view2 is deactivated','');
- $this->verifyTextNotPresent('view3 is activated','');
- $this->verifyTextPresent('view3 is deactivated','');
+ $this->assertTextNotPresent('view1 is activated','');
+ $this->assertTextNotPresent('view1 is deactivated','');
+ $this->assertTextPresent('view2 is activated','');
+ $this->assertTextNotPresent('view2 is deactivated','');
+ $this->assertTextNotPresent('view3 is activated','');
+ $this->assertTextPresent('view3 is deactivated','');
// goto view1
$this->clickAndWait('name=ctl0$Content$ctl2');
- $this->verifyTextPresent('view1 is activated','');
- $this->verifyTextNotPresent('view1 is deactivated','');
- $this->verifyTextNotPresent('view2 is activated','');
- $this->verifyTextPresent('view2 is deactivated','');
- $this->verifyTextNotPresent('view3 is activated','');
- $this->verifyTextNotPresent('view3 is deactivated','');
+ $this->assertTextPresent('view1 is activated','');
+ $this->assertTextNotPresent('view1 is deactivated','');
+ $this->assertTextNotPresent('view2 is activated','');
+ $this->assertTextPresent('view2 is deactivated','');
+ $this->assertTextNotPresent('view3 is activated','');
+ $this->assertTextNotPresent('view3 is deactivated','');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket246TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket246TestCase.php
index bedd6e2c..7c4fe364 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket246TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket246TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket246TestCase extends PradoGenericSeleniumTest
+class Ticket246TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket246');
- $this->assertTitle('Verifying Ticket 246');
+ $this->url('tickets/index.php?page=Ticket246');
+ $this->assertEquals($this->title(), 'Verifying Ticket 246');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket274TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket274TestCase.php
index b2b17de7..6da15a47 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket274TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket274TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket274TestCase extends PradoGenericSeleniumTest
+class Ticket274TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket274');
- $this->assertTitle('Verifying Ticket 274');
+ $this->url('tickets/index.php?page=Ticket274');
+ $this->assertEquals($this->title(), 'Verifying Ticket 274');
$this->assertNotVisible($base.'validator1');
$this->assertNotVisible($base.'validator2');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket278TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket278TestCase.php
index 4bfffede..2b1d4c09 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket278TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket278TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket278TestCase extends PradoGenericSeleniumTest
+class Ticket278TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket278');
- $this->assertTitle('Verifying Ticket 278');
+ $this->url('tickets/index.php?page=Ticket278');
+ $this->assertEquals($this->title(), 'Verifying Ticket 278');
$this->assertNotVisible($base.'validator1');
$this->assertNotVisible($base.'validator2');
$this->assertNotVisible($base.'panel1');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket27TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket27TestCase.php
index 7defd7ae..a57d83a6 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket27TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket27TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket27TestCase extends PradoGenericSeleniumTest
+class Ticket27TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket27');
+ $this->url('tickets/index.php?page=Ticket27');
$this->verifyTitle("Verifying Ticket 27", "");
$this->click("//input[@value='Agree']", "");
$this->assertVisible("ctl0_Content_validator1", "");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket284TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket284TestCase.php
index d28ea771..08c0338c 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket284TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket284TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket284TestCase extends PradoGenericSeleniumTest
+class Ticket284TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket284');
+ $this->url('tickets/index.php?page=Ticket284');
$this->assertTextPresent('Verifying Ticket 284');
$this->click('ctl0_Content_ctl1');
-
+
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket285TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket285TestCase.php
index 8b996964..76f1c271 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket285TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket285TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket285TestCase extends PradoGenericSeleniumTest
+class Ticket285TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket285');
+ $this->url('tickets/index.php?page=Ticket285');
$this->assertTextPresent('350.00');
$this->assertTextPresent('349.99');
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket28TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket28TestCase.php
index 1f64b3f9..c0364ce6 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket28TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket28TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket28TestCase extends PradoGenericSeleniumTest
+class Ticket28TestCase extends PradoGenericSelenium2Test
{
-
+
function test()
{
- $this->open('tickets/index.php?page=Ticket28');
+ $this->url('tickets/index.php?page=Ticket28');
$this->assertTextPresent('Label 1');
$this->clickAndWait('link=Click Me');
$this->assertTextPresent('Link Button 1 Clicked!');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket290TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket290TestCase.php
index f541d63d..0dc95e87 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket290TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket290TestCase.php
@@ -1,28 +1,27 @@
<?php
/**
-*
+*
*/
-class Ticket290TestCase extends PradoGenericSeleniumTest
+class Ticket290TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket290');
- $this->assertTitle("Verifying Ticket 290");
-
+ $this->url('tickets/index.php?page=Ticket290');
+ $this->assertEquals($this->title(), "Verifying Ticket 290");
+
$this->assertText("{$base}label1", "Label 1");
$this->assertText("{$base}label2", "Label 2");
$this->type("{$base}textbox1", "test");
- // bad hack to simulate enter key..
- $this->submit('ctl0_ctl1');
+
+ $this->click("{$base}textbox1");
+ $this->keys(PHPUnit_Extensions_Selenium2TestCase_Keys::ENTER);
$this->pause(800);
-
- $this->assertText("{$base}label1", "Doing Validation");
- // this can't work properly without manual testing
- //$this->assertText("{$base}label2", "Button 2 (default) Clicked!");
+ $this->assertText("{$base}label1", "Doing Validation");
+ $this->assertText("{$base}label2", "Button 2 (default) Clicked!");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket433TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket433TestCase.php
index b8462988..b1f7ed00 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket433TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket433TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket433TestCase extends PradoGenericSeleniumTest
+class Ticket433TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket433');
- $this->assertTitle("Verifying Ticket 433");
+ $this->url('tickets/index.php?page=Ticket433');
+ $this->assertEquals($this->title(), "Verifying Ticket 433");
$this->assertText("{$base}VoteClick", "BEFORE click");
$this->click("{$base}VoteClick");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket439TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket439TestCase.php
index c393de91..e7991cd6 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket439TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket439TestCase.php
@@ -1,15 +1,14 @@
<?php
-class Ticket439TestCase extends PradoGenericSeleniumTest
+class Ticket439TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket439');
- $this->assertTitle("Verifying Ticket 439");
+ $this->url('tickets/index.php?page=Ticket439');
+ $this->assertEquals($this->title(), "Verifying Ticket 439");
$this->click("{$base}button1");
- $this->waitForPageToLoad(3000);
$this->pause(800);
- $this->assertTitle("Verifying Home");
+ $this->assertEquals($this->title(), "Verifying Home");
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket463TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket463TestCase.php
index 34ffb8fd..1901ae50 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket463TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket463TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket463TestCase extends PradoGenericSeleniumTest
+class Ticket463TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket463');
+ $this->url('tickets/index.php?page=Ticket463');
$this->verifyTitle("Verifying Ticket 463", "");
$this->assertTextPresent('May 1, 2005 12:00:00 AM');
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket470TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket470TestCase.php
index 4a2804ea..6c40927a 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket470TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket470TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket470TestCase extends PradoGenericSeleniumTest
+class Ticket470TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket470');
+ $this->url('tickets/index.php?page=Ticket470');
$this->verifyTitle("Verifying Ticket 470");
$this->assertText("{$base}counter", "0");
$this->assertText("{$base}Results", "");
@@ -38,7 +38,7 @@ class Ticket470TestCase extends PradoGenericSeleniumTest
$this->assertText("{$base}counter", "1");
$this->assertText("{$base}Results", "");
$this->assertVisible("{$base}validator1");
-
+
$this->type("{$base}TextBox", "test");
$this->click("{$base}button1");
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Ticket477TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket477TestCase.php
index 16ebc56e..13f2740a 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket477TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket477TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket477TestCase extends PradoGenericSeleniumTest
+class Ticket477TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket477');
- $this->assertTitle("Verifying Ticket 477");
+ $this->url('tickets/index.php?page=Ticket477');
+ $this->assertEquals($this->title(), "Verifying Ticket 477");
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket488TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket488TestCase.php
index c3b2f43f..7940338f 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket488TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket488TestCase.php
@@ -1,40 +1,41 @@
<?php
-class Ticket488TestCase extends PradoGenericSeleniumTest
+class Ticket488TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('active-controls/index.php?page=CustomValidatorByPass');
+ $base='ctl0_Content_';
+ $this->url('active-controls/index.php?page=CustomValidatorByPass');
$this->assertTextPresent('Custom Login');
$this->assertNotVisible('loginBox');
$this->click("showLogin");
$this->assertVisible("loginBox");
- $this->assertNotVisible("validator1");
- $this->assertNotVisible("validator2");
+ $this->assertNotVisible("{$base}validator1");
+ $this->assertNotVisible("{$base}validator2");
- $this->click("checkLogin");
+ $this->click("{$base}checkLogin");
$this->pause(800);
- $this->assertVisible("validator1");
- $this->assertNotVisible("validator2");
+ $this->assertVisible("{$base}validator1");
+ $this->assertNotVisible("{$base}validator2");
- $this->type('Username', 'tea');
- $this->type('Password', 'mmama');
+ $this->type("{$base}Username", 'tea');
+ $this->type("{$base}Password", 'mmama');
- $this->click("checkLogin");
+ $this->click("{$base}checkLogin");
$this->pause(800);
- $this->assertNotVisible("validator1");
- $this->assertVisible("validator2");
+ $this->assertNotVisible("{$base}validator1");
+ $this->assertVisible("{$base}validator2");
- $this->type('Password', 'test');
- $this->click("checkLogin");
+ $this->type("{$base}Password", 'test');
+ $this->click("{$base}checkLogin");
$this->pause(800);
- $this->assertNotVisible("validator1");
- $this->assertNotVisible("validator2");
+ $this->assertNotVisible("{$base}validator1");
+ $this->assertNotVisible("{$base}validator2");
}
function test_more()
{
- $this->open('tickets/index.php?page=Ticket488');
+ $this->url('tickets/index.php?page=Ticket488');
//add test assertions here.
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket504TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket504TestCase.php
index 63ecfe2f..7ffa7428 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket504TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket504TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket504TestCase extends PradoGenericSeleniumTest
+class Ticket504TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket504');
+ $this->url('tickets/index.php?page=Ticket504');
$this->verifyTitle("Verifying Ticket 504", "");
$this->assertText("status", "");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket507TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket507TestCase.php
index 19d54e9b..0b90749b 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket507TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket507TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket507TestCase extends PradoGenericSeleniumTest
+class Ticket507TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base='ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket507');
+ $this->url('tickets/index.php?page=Ticket507');
$this->verifyTitle("Verifying Ticket 507", "");
$this->assertText("{$base}label1", "Label 1");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php
index 2df88612..dfc81a3d 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket521TestCase extends PradoGenericSeleniumTest
+class Ticket521TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open("tickets/index.php?page=Ticket521");
- $this->assertTitle("Verifying Ticket 521");
+ $this->url("tickets/index.php?page=Ticket521");
+ $this->assertEquals($this->title(), "Verifying Ticket 521");
$this->assertText("{$base}label1", "Label 1");
$this->click("{$base}button1");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket526TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket526TestCase.php
index 7476db69..6a7ee693 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket526TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket526TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket526TestCase extends PradoGenericSeleniumTest
+class Ticket526TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket526');
+ $this->url('tickets/index.php?page=Ticket526');
$this->verifyTitle("Verifying Ticket 526", "");
$this->assertElementNotPresent("{$base}dpbutton");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket528TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket528TestCase.php
index 3903000a..7fb24d04 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket528TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket528TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket528TestCase extends PradoGenericSeleniumTest
+class Ticket528TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket528');
- $this->assertTitle("Verifying Ticket 528");
+ $this->url('tickets/index.php?page=Ticket528');
+ $this->assertEquals($this->title(), "Verifying Ticket 528");
$this->select("{$base}DDropTurno", "Tarde");
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Ticket535TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket535TestCase.php
index 26f5a7d7..6634ed93 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket535TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket535TestCase.php
@@ -1,34 +1,34 @@
<?php
-class Ticket535TestCase extends PradoGenericSeleniumTest
+class Ticket535TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket535');
- $this->assertTitle("Verifying Ticket 535");
+ $this->url('tickets/index.php?page=Ticket535');
+ $this->assertEquals($this->title(), "Verifying Ticket 535");
$this->assertText("{$base}label1", "Label 1");
$this->click("{$base}radio1");
$this->click("{$base}button1");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:radio1 checked:{1} radio2 checked:{}');
+ $this->assertText("{$base}label1", 'radio1 checked:{1} radio2 checked:{}');
$this->click("{$base}radio2");
$this->click("{$base}button1");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:radio1 checked:{1} radio2 checked:{1}');
+ $this->assertText("{$base}label1", 'radio1 checked:{1} radio2 checked:{1}');
$this->click("{$base}bad_radio1");
$this->click("{$base}button2");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio1 checked:{1} bad_radio2 checked:{}');
+ $this->assertText("{$base}label1", 'bad_radio1 checked:{1} bad_radio2 checked:{}');
$this->click("{$base}bad_radio2");
$this->click("{$base}button2");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio1 checked:{} bad_radio2 checked:{1}');
+ $this->assertText("{$base}label1", 'bad_radio1 checked:{} bad_radio2 checked:{1}');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket538TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket538TestCase.php
index 16b0f863..edec5750 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket538TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket538TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket538TestCase extends PradoGenericSeleniumTest
+class Ticket538TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket538');
+ $this->url('tickets/index.php?page=Ticket538');
$this->verifyTitle("Verifying Ticket 538", "");
$this->assertText("{$base}ALLog", 'waiting for response...');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket54TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket54TestCase.php
index f8e5a469..86923010 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket54TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket54TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket54TestCase extends PradoGenericSeleniumTest
+class Ticket54TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket54');
- $this->verifyTextPresent("|A|a|B|b|C|", "");
+ $this->url('tickets/index.php?page=Ticket54');
+ $this->assertTextPresent("|A|a|B|b|C|", "");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket573TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket573TestCase.php
index 996d72e9..1f9461be 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket573TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket573TestCase.php
@@ -1,10 +1,10 @@
<?php
-class Ticket573TestCase extends PradoGenericSeleniumTest
+class Ticket573TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket573');
+ $this->url('tickets/index.php?page=Ticket573');
$this->verifyTitle("Verifying Ticket 573", "");
$this->assertText('test1', '10.00');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket578TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket578TestCase.php
index 47330326..ae0c991b 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket578TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket578TestCase.php
@@ -1,22 +1,22 @@
<?php
-class Ticket578TestCase extends PradoGenericSeleniumTest
+class Ticket578TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket578');
+ $this->url('tickets/index.php?page=Ticket578');
$this->verifyTitle("Verifying Ticket 578", "");
$this->assertText("{$base}label1", "Label 1");
$this->click("{$base}button1", "");
$this->pause(800);
- $this->assertText("{$base}label1", "Button 1 was clicked : ");
+ $this->assertText("{$base}label1", "Button 1 was clicked :");
$text="helloworld";
$this->runScript("tinyMCE.get('{$base}text1').setContent('{$text}')");
$this->click("{$base}button1", "");
$this->pause(800);
- $this->assertText("{$base}label1", "exact:Button 1 was clicked : <p>{$text}</p>");
+ $this->assertText("{$base}label1", "Button 1 was clicked : <p>{$text}</p>");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket585TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket585TestCase.php
index 8b2d36b3..5a9dd8d4 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket585TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket585TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket585TestCase extends PradoGenericSeleniumTest
+class Ticket585TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket585');
+ $this->url('tickets/index.php?page=Ticket585');
$this->verifyTitle("Verifying Ticket 585", "");
$this->assertText("error", "");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket586TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket586TestCase.php
index 612c086a..50efd50a 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket586TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket586TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket586TestCase extends PradoGenericSeleniumTest
+class Ticket586TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket586');
+ $this->url('tickets/index.php?page=Ticket586');
$this->verifyTitle("Verifying Ticket 586", "");
$this->assertText("{$base}label1", "Status");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket587TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket587TestCase.php
index 7fa37bad..b4ddc287 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket587TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket587TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket587TestCase extends PradoGenericSeleniumTest
+class Ticket587TestCase extends PradoGenericSelenium2Test
{
function testKeyPress()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket587_reopened');
- $this->assertTitle("Verifying Ticket 587_reopened");
+ $this->url('tickets/index.php?page=Ticket587_reopened');
+ $this->assertEquals($this->title(), "Verifying Ticket 587_reopened");
$this->assertText($base."label1", "Label 1");
$this->select($base."list1", "item 3");
@@ -26,8 +26,8 @@ class Ticket587TestCase extends PradoGenericSeleniumTest
function testButtonClick()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket587_reopened');
- $this->assertTitle("Verifying Ticket 587_reopened");
+ $this->url('tickets/index.php?page=Ticket587_reopened');
+ $this->assertEquals($this->title(), "Verifying Ticket 587_reopened");
$this->assertText($base."label1", "Label 1");
$this->select($base."list1", "item 3");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket592TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket592TestCase.php
index ec8d2284..14467952 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket592TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket592TestCase.php
@@ -1,45 +1,45 @@
<?php
-class Ticket592TestCase extends PradoGenericSeleniumTest
+class Ticket592TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket592');
- $this->assertTitle("Verifying Ticket 592");
+ $this->url('tickets/index.php?page=Ticket592');
+ $this->assertEquals($this->title(), "Verifying Ticket 592");
$this->assertText("{$base}label1", "Label 1");
$this->click("{$base}radio1");
$this->click("{$base}button1");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:radio1 checked:{1} radio2 checked:{}');
+ $this->assertText("{$base}label1", 'radio1 checked:{1} radio2 checked:{}');
$this->click("{$base}radio2");
$this->click("{$base}button1");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:radio1 checked:{1} radio2 checked:{1}');
+ $this->assertText("{$base}label1", 'radio1 checked:{1} radio2 checked:{1}');
$this->click("{$base}bad_radio1");
$this->click("{$base}button2");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio1 checked:{1} bad_radio2 checked:{}');
+ $this->assertText("{$base}label1", 'bad_radio1 checked:{1} bad_radio2 checked:{}');
$this->click("{$base}bad_radio2");
$this->click("{$base}button2");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio1 checked:{} bad_radio2 checked:{1}');
-
+ $this->assertText("{$base}label1", 'bad_radio1 checked:{} bad_radio2 checked:{1}');
+
$this->click("{$base}bad_radio3");
$this->click("{$base}button3");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio3 checked:{1} bad_radio4 checked:{}');
+ $this->assertText("{$base}label1", 'bad_radio3 checked:{1} bad_radio4 checked:{}');
$this->click("{$base}bad_radio4");
$this->click("{$base}button3");
$this->pause(800);
- $this->assertText("{$base}label1", 'exact:bad_radio3 checked:{} bad_radio4 checked:{1}');
-
+ $this->assertText("{$base}label1", 'bad_radio3 checked:{} bad_radio4 checked:{1}');
+
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket595TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket595TestCase.php
index 14b2f985..0781b506 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket595TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket595TestCase.php
@@ -1,37 +1,37 @@
<?php
-class Ticket595TestCase extends PradoGenericSeleniumTest
+class Ticket595TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket595');
- $this->assertTitle("Verifying Ticket 595");
-
+ $this->url('tickets/index.php?page=Ticket595');
+ $this->assertEquals($this->title(), "Verifying Ticket 595");
+
$this->click($base.'ctl2');
- $this->assertAttribute($base.'A@class','errorclassA');
-
+ $this->verifyAttribute($base.'A@class','errorclassA');
+
$this->type($base.'A', 'Prado');
$this->click($base.'ctl2');
- $this->assertAttribute($base.'A@class','errorclassA');
-
+ $this->verifyAttribute($base.'A@class','errorclassA');
+
$this->type($base.'A', 'test@pradosoft.com');
$this->click($base.'ctl2');
$this->pause(800);
- $this->assertAttribute($base.'A@class','');
+ $this->verifyAttribute($base.'A@class','');
$this->click($base.'ctl5');
$this->pause(800);
- $this->assertAttribute($base.'B@class','exact: errorclassB');
-
+ $this->verifyAttribute($base.'B@class',' errorclassB');
+
$this->type($base.'B', 'Prado');
$this->click($base.'ctl5');
$this->pause(800);
- $this->assertAttribute($base.'B@class','exact: errorclassB');
-
+ $this->verifyAttribute($base.'B@class',' errorclassB');
+
$this->type($base.'B', 'test@pradosoft.com');
$this->click($base.'ctl5');
$this->pause(800);
- $this->assertAttribute($base.'B@class','');
+ $this->verifyAttribute($base.'B@class','');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket622TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket622TestCase.php
index 0d0fe3d2..e26da1f1 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket622TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket622TestCase.php
@@ -1,17 +1,17 @@
<?php
-class Ticket622TestCase extends PradoGenericSeleniumTest
+class Ticket622TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket622');
- $this->assertTitle("Verifying Ticket 622");
-
+ $this->url('tickets/index.php?page=Ticket622');
+ $this->assertEquals($this->title(), "Verifying Ticket 622");
+
$this->click($base.'ctl0');
$this->pause(800);
- $this->assertAttribute($base.'ALB@style',';');
- $this->assertAttribute('css=span#acb span@style', ';');
- $this->assertAttribute('css=span#arb span@style', ';');
+ $this->verifyAttribute($base.'ALB@style','');
+ $this->verifyAttribute('css=span#acb span@style', '');
+ $this->verifyAttribute('css=span#arb span@style', '');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket653TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket653TestCase.php
index ec5eceb4..fbf569bb 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket653TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket653TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket653TestCase extends PradoGenericSeleniumTest
+class Ticket653TestCase extends PradoGenericSelenium2Test
{
function test()
{
// Open with 'Friendly URL'
- $this->open('tickets/index.php/ticket653');
+ $this->url('tickets/index.php/ticket653');
$this->verifyTitle("Verifying Ticket 653", "");
$this->assertText('textspan', 'This is the page for Ticket653');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php
index 9fe238b9..af0c8f02 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket656TestCase extends PradoGenericSeleniumTest
+class Ticket656TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket656');
- $this->assertTitle("Verifying Ticket 656");
+ $this->url('tickets/index.php?page=Ticket656');
+ $this->assertEquals($this->title(), "Verifying Ticket 656");
// First test, current date
$this->click($base."btnUpdate");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket659TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket659TestCase.php
index 91326e9d..bb1a021d 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket659TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket659TestCase.php
@@ -1,18 +1,18 @@
<?php
-class Ticket659TestCase extends PradoGenericSeleniumTest
+class Ticket659TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
// Normal component (working)
- $this->open('tickets/index.php?page=ToggleTest');
+ $this->url('tickets/index.php?page=ToggleTest');
$this->assertText("${base}lbl", "Down");
$this->click("${base}btn", "");
$this->pause(800);
$this->assertText("${base}lbl", "Up");
// Extended component (not working)
- $this->open('tickets/index.php?page=Ticket659');
+ $this->url('tickets/index.php?page=Ticket659');
$this->assertText("${base}lbl", "Down");
$this->click("${base}btn", "");
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Ticket660TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket660TestCase.php
index e0c97e53..f77e5fac 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket660TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket660TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket660TestCase extends PradoGenericSeleniumTest
+class Ticket660TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket660');
- $this->assertTitle("Verifying Ticket 660");
-
+ $this->url('tickets/index.php?page=Ticket660');
+ $this->assertEquals($this->title(), "Verifying Ticket 660");
+
$this->click($base.'PB');
$this->pause(800);
$this->assertText($base.'A','ÄÖÜ äöü');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket669TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket669TestCase.php
index b6931808..6afb1072 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket669TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket669TestCase.php
@@ -1,47 +1,47 @@
<?php
-class Ticket669TestCase extends PradoGenericSeleniumTest
+class Ticket669TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket669');
- $this->assertTitle("Verifying Ticket 669");
-
+ $this->url('tickets/index.php?page=Ticket669');
+ $this->assertEquals($this->title(), "Verifying Ticket 669");
+
$this->assertTextPresent('1 - Test without callback');
- $this->assertValue($base.'tb1', 'exact:ActiveTextBox');
- $this->assertValue($base.'tb2', 'exact:TextBox in ActivePanel');
-
+ $this->assertValue($base.'tb1', 'ActiveTextBox');
+ $this->assertValue($base.'tb2', 'TextBox in ActivePanel');
+
$this->click($base.'ctl4');
$this->pause(800);
- $this->assertValue($base.'tb1', 'exact:ActiveTextBox +1');
- $this->assertValue($base.'tb2', 'exact:TextBox in ActivePanel +1');
-
+ $this->assertValue($base.'tb1', 'ActiveTextBox +1');
+ $this->assertValue($base.'tb2', 'TextBox in ActivePanel +1');
+
$this->click($base.'ctl1');
$this->pause(800);
$this->assertTextPresent('2 - Test callback with 2nd ActivePanel');
- $this->assertValue($base.'tb3', 'exact:ActiveTextBox');
- $this->assertValue($base.'tb4', 'exact:TextBox in ActivePanel');
- $this->assertValue($base.'tb5', 'exact:TextBox in ActivePanel');
-
+ $this->assertValue($base.'tb3', 'ActiveTextBox');
+ $this->assertValue($base.'tb4', 'TextBox in ActivePanel');
+ $this->assertValue($base.'tb5', 'TextBox in ActivePanel');
+
$this->click($base.'ctl6');
$this->pause(800);
-
- $this->assertValue($base.'tb3', 'exact:ActiveTextBox +1');
- $this->assertValue($base.'tb4', 'exact:TextBox in ActivePanel +1');
- $this->assertValue($base.'tb5', 'exact:TextBox in ActivePanel +1');
-
+
+ $this->assertValue($base.'tb3', 'ActiveTextBox +1');
+ $this->assertValue($base.'tb4', 'TextBox in ActivePanel +1');
+ $this->assertValue($base.'tb5', 'TextBox in ActivePanel +1');
+
$this->click($base.'ctl2');
$this->pause(800);
$this->assertTextPresent('3 - Test callback without 2nd ActivePanel');
- $this->assertValue($base.'tb6', 'exact:ActiveTextBox');
- $this->assertValue($base.'tb7', 'exact:TextBox in Panel');
-
+ $this->assertValue($base.'tb6', 'ActiveTextBox');
+ $this->assertValue($base.'tb7', 'TextBox in Panel');
+
$this->click($base.'ctl8');
$this->pause(800);
-
- $this->assertValue($base.'tb6', 'exact:ActiveTextBox +1');
- $this->assertValue($base.'tb7', 'exact:TextBox in Panel +1');
-
+
+ $this->assertValue($base.'tb6', 'ActiveTextBox +1');
+ $this->assertValue($base.'tb7', 'TextBox in Panel +1');
+
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket670TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket670TestCase.php
index 33e45b49..f0387746 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket670TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket670TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket670TestCase extends PradoGenericSeleniumTest
+class Ticket670TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket670');
- $this->assertTitle("Verifying Ticket 670");
-
+ $this->url('tickets/index.php?page=Ticket670');
+ $this->assertEquals($this->title(), "Verifying Ticket 670");
+
$this->type($base."datePicker", '07-07-2003');
$this->pause(800);
//$this->assertText($base."datePicker",'07-07-2003');
@@ -15,7 +15,7 @@ class Ticket670TestCase extends PradoGenericSeleniumTest
$this->click($base."ok");
$this->pause(800);
$this->assertText($base."lbl",'07-07-2007');
-
+
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket671TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket671TestCase.php
index 031dc991..53330ca4 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket671TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket671TestCase.php
@@ -1,41 +1,41 @@
<?php
-class Ticket671TestCase extends PradoGenericSeleniumTest
+class Ticket671TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket671');
- $this->assertTitle("Verifying Ticket 671");
-
- $this->verifyNotVisible($base.'ctl0');
+ $this->url('tickets/index.php?page=Ticket671');
+ $this->assertEquals($this->title(), "Verifying Ticket 671");
+
+ $this->assertNotVisible($base.'ctl0');
// Click submit
$this->click($base.'ctl1');
$this->pause(800);
- $this->verifyText($base.'ctl0', 'Please Select Test 3');
- $this->verifyVisible($base.'ctl0');
+ $this->assertText($base.'ctl0', 'Please Select Test 3');
+ $this->assertVisible($base.'ctl0');
$this->select($base.'addl', 'Test 2');
$this->pause(800);
- $this->verifyVisible($base.'ctl0');
- $this->verifyText($base."lblResult", "You have selected 'Test 2'. But this is not valid !");
+ $this->assertVisible($base.'ctl0');
+ $this->assertText($base."lblResult", "You have selected 'Test 2'. But this is not valid !");
$this->select($base.'addl', 'Test 3');
$this->pause(800);
- $this->verifyNotVisible($base.'ctl0');
- $this->verifyText($base."lblResult", "You have selected 'Test 3'.");
+ $this->assertNotVisible($base.'ctl0');
+ $this->assertText($base."lblResult", "You have selected 'Test 3'.");
$this->click($base.'ctl1');
$this->pause(800);
- $this->verifyText($base."lblResult", "You have successfully validated the form");
-
+ $this->assertText($base."lblResult", "You have successfully validated the form");
+
$this->type($base.'testTextBox', 'test');
$this->pause(800);
$this->click($base.'ctl3');
$this->pause(800);
- $this->verifyVisible($base.'ctl2');
+ $this->assertVisible($base.'ctl2');
$this->type($base.'testTextBox',"Prado");
$this->pause(800);
$this->click($base.'ctl3');
$this->pause(800);
- $this->verifyNotVisible($base.'ctl2');
- $this->verifyText($base.'lblResult2', 'Thanks !');
+ $this->assertNotVisible($base.'ctl2');
+ $this->assertText($base.'lblResult2', 'Thanks !');
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket671_reopenedTestCase.php b/tests/FunctionalTests/tickets/tests/Ticket671_reopenedTestCase.php
index 7ba24dcc..02201075 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket671_reopenedTestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket671_reopenedTestCase.php
@@ -1,46 +1,46 @@
<?php
-class Ticket671_reopenedTestCase extends PradoGenericSeleniumTest
+class Ticket671_reopenedTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket671_reopened');
- $this->assertTitle("Verifying Ticket 671_reopened");
+ $this->url('tickets/index.php?page=Ticket671_reopened');
+ $this->assertEquals($this->title(), "Verifying Ticket 671_reopened");
// Type wrong value
$this->type($base.'testField', 'abcd');
$this->click($base.'ctl4');
$this->pause(800);
$this->assertVisible($base.'ctl2');
- $this->assertText($base.'Result', 'exact:Check callback called (1) --- Save callback called DATA NOK');
-
+ $this->assertText($base.'Result', 'Check callback called (1) --- Save callback called DATA NOK');
+
// Reclick, should not have any callback
$this->click($base.'ctl4');
$this->pause(800);
$this->assertVisible($base.'ctl2');
- $this->assertText($base.'Result', 'exact:Check callback called (2) --- Save callback called DATA NOK');
-
+ $this->assertText($base.'Result', 'Check callback called (2) --- Save callback called DATA NOK');
+
// Type right value
$this->type($base.'testField', 'Test');
$this->click($base.'ctl4');
$this->pause(800);
$this->assertNotVisible($base.'ctl2');
- $this->assertText($base.'Result', 'exact:Check callback called (3) --- Save callback called DATA OK');
-
+ $this->assertText($base.'Result', 'Check callback called (3) --- Save callback called DATA OK');
+
// Type empty value
$this->type($base.'testField', '');
$this->click($base.'ctl4');
$this->pause(800);
$this->assertVisible($base.'ctl1');
$this->assertNotVisible($base.'ctl2');
- $this->assertText($base.'Result', 'exact:Check callback called (3) --- Save callback called DATA OK');
-
+ $this->assertText($base.'Result', 'Check callback called (3) --- Save callback called DATA OK');
+
// Type right value
$this->type($base.'testField', 'Test');
$this->click($base.'ctl4');
$this->pause(800);
$this->assertNotVisible($base.'ctl1');
$this->assertNotVisible($base.'ctl2');
- $this->assertText($base.'Result', 'exact:Check callback called (4) --- Save callback called DATA OK');
+ $this->assertText($base.'Result', 'Check callback called (4) --- Save callback called DATA OK');
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket679TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket679TestCase.php
index 4ee22c20..af957fa3 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket679TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket679TestCase.php
@@ -1,18 +1,18 @@
<?php
-class Ticket679TestCase extends PradoGenericSeleniumTest
+class Ticket679TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket679');
- $this->assertTitle("Verifying Ticket 679");
-
+ $this->url('tickets/index.php?page=Ticket679');
+ $this->assertEquals($this->title(), "Verifying Ticket 679");
+
// First part of ticket : Repeater bug
$this->click($base."ctl0");
$this->pause(800);
$this->assertText($base."myLabel",'outside');
- $this->verifyVisible($base."myLabel");
-
+ $this->assertVisible($base."myLabel");
+
// Reload completly the page
$this->refresh();
$this->pause(800);
@@ -20,16 +20,16 @@ class Ticket679TestCase extends PradoGenericSeleniumTest
$this->click($base."Repeater_ctl0_ctl0");
$this->pause(800);
$this->assertText($base."myLabel",'inside');
- $this->verifyVisible($base."myLabel");
-
+ $this->assertVisible($base."myLabel");
+
// Second part of ticket : ARB bug
- $this->verifyNotChecked($base."myRadioButton");
+ $this->assertNotChecked($base."myRadioButton");
$this->click($base."ctl1");
$this->pause(800);
- $this->verifyChecked($base."myRadioButton");
+ $this->assertChecked($base."myRadioButton");
$this->click($base."ctl2");
$this->pause(800);
- $this->verifyNotChecked($base."myRadioButton");
+ $this->assertNotChecked($base."myRadioButton");
$this->pause(800);
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket691TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket691TestCase.php
index a441f82c..ae6cd7d3 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket691TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket691TestCase.php
@@ -1,16 +1,16 @@
<?php
-class Ticket691TestCase extends PradoGenericSeleniumTest
+class Ticket691TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket691');
- $this->assertTitle("Verifying Ticket 691");
-
- $this->click($base."List_c2");
+ $this->url('tickets/index.php?page=Ticket691');
+ $this->assertEquals($this->title(), "Verifying Ticket 691");
+
+ $this->click("//input[@id='{$base}List_c2']/../..");
$this->pause(800);
- $this->assertText($base."Title", "Thanks");
- $this->assertText($base."Result", "You vote 3");
+ $this->assertText("{$base}Title", "Thanks");
+ $this->assertText("{$base}Result", "You vote 3");
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket698TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket698TestCase.php
index 8f58a320..5c8c46aa 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket698TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket698TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket698TestCase extends PradoGenericSeleniumTest
+class Ticket698TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket698');
- $this->assertTitle("Verifying Ticket 698");
-
+ $this->url('tickets/index.php?page=Ticket698');
+ $this->assertEquals($this->title(), "Verifying Ticket 698");
+
$this->click($base."switchContentTypeButton");
$this->pause(800);
$this->assertVisible($base."EditHtmlTextBox");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket700TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket700TestCase.php
index 0366c2fc..d14823bf 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket700TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket700TestCase.php
@@ -1,13 +1,13 @@
<?php
-class Ticket700TestCase extends PradoGenericSeleniumTest
+class Ticket700TestCase extends PradoGenericSelenium2Test
{
function test()
{
// page: Home
- $this->open('tickets/index700.php');
+ $this->url('tickets/index700.php');
$this->clickAndWait('ctl0_Logout');
$this->clickAndWait('pageHome');
- $this->assertTitle("Home");
+ $this->assertEquals($this->title(), "Home");
$this->assertTextPresent('|Param1: Set at app config|');
$this->assertTextPresent('|Param2: Set at root|');
$this->assertTextPresent('|Param3: default 3|');
@@ -16,12 +16,12 @@ class Ticket700TestCase extends PradoGenericSeleniumTest
// page: admin.Home
$this->clickAndWait('pageAdminHome');
- $this->assertTitle('UserLogin');
+ $this->assertEquals($this->title(), 'UserLogin');
$this->type('ctl0_Main_Username','AdminUser');
$this->type('ctl0_Main_Password','demo');
$this->clickAndWait('ctl0_Main_LoginButton');
$this->clickAndWait('pageAdminHome');
- $this->assertTitle('admin.Home');
+ $this->assertEquals($this->title(), 'admin.Home');
$this->assertTextPresent('|Param1: Set at app config|');
$this->assertTextPresent('|Param2: Set at admin|');
$this->assertTextPresent('|Param3: Set at admin|');
@@ -30,24 +30,24 @@ class Ticket700TestCase extends PradoGenericSeleniumTest
// page: admin.Home2
$this->clickAndWait('pageAdminHome2');
- $this->assertTitle('admin.Home2');
+ $this->assertEquals($this->title(), 'admin.Home2');
$this->clickAndWait('ctl0_Logout');
$this->clickAndWait('pageAdminHome2');
- $this->assertTitle('admin.Home2');
+ $this->assertEquals($this->title(), 'admin.Home2');
// page: admin.users.Home
$this->clickAndWait('pageAdminUsersHome');
- $this->assertTitle('UserLogin');
+ $this->assertEquals($this->title(), 'UserLogin');
$this->type('ctl0_Main_Username','NormalUser');
$this->type('ctl0_Main_Password','demo');
$this->clickAndWait('ctl0_Main_LoginButton');
$this->clickAndWait('pageAdminUsersHome');
- $this->assertTitle('UserLogin');
+ $this->assertEquals($this->title(), 'UserLogin');
$this->type('ctl0_Main_Username','AdminUser');
$this->type('ctl0_Main_Password','demo');
$this->clickAndWait('ctl0_Main_LoginButton');
$this->clickAndWait('pageAdminUsersHome');
- $this->assertTitle('admin.users.Home');
+ $this->assertEquals($this->title(), 'admin.users.Home');
$this->assertTextPresent('|Param1: Set at admin|');
$this->assertTextPresent('|Param2: Set at admin.users|');
$this->assertTextPresent('|Param3: default 3|');
@@ -56,11 +56,11 @@ class Ticket700TestCase extends PradoGenericSeleniumTest
// page: admin.users.Home2
$this->clickAndWait('pageAdminUsersHome2');
- $this->assertTitle('admin.users.Home2');
+ $this->assertEquals($this->title(), 'admin.users.Home2');
// page: content.Home
$this->clickAndWait('pageContentHome');
- $this->assertTitle('content.Home');
+ $this->assertEquals($this->title(), 'content.Home');
$this->assertTextPresent('|Param1: Set at app config|');
$this->assertTextPresent('|Param2: Set at root|');
$this->assertTextPresent('|Param3: default 3|');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket703TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket703TestCase.php
index dedb491f..3b278557 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket703TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket703TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket703TestCase extends PradoGenericSeleniumTest
+class Ticket703TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket703.Ticket703');
- $this->assertTitle("Verifying Ticket703.Ticket703 703.703");
+ $this->url('tickets/index.php?page=Ticket703.Ticket703');
+ $this->assertEquals($this->title(), "Verifying Ticket703.Ticket703 703.703");
// Start with an empty log
$this->click($base.'ctl2');
// Wait for callback to be lanched
@@ -16,7 +16,7 @@ class Ticket703TestCase extends PradoGenericSeleniumTest
$this->click($base.'ctl0');
$this->pause(800);
$this->click($base.'ctl1');
- $this->assertTextPresent($base.'logBox', "Test of prado logging system");
+ $this->assertTextPresent($base.'logBox', "Test of prado logging system");
// Clean log for next run
$this->click($base.'ctl2');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket708TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket708TestCase.php
index 87509b29..b10b070a 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket708TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket708TestCase.php
@@ -1,24 +1,24 @@
<?php
-class Ticket708TestCase extends PradoGenericSeleniumTest
+class Ticket708TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket708');
- $this->assertTitle("Verifying Ticket 708");
-
+ $this->url('tickets/index.php?page=Ticket708');
+ $this->assertEquals($this->title(), "Verifying Ticket 708");
+
$this->click($base."grid_ctl1_RadioButton");
$this->pause(800);
$this->assertText($base."Result", "You have selected Radio Button #1");
-
+
$this->click($base."grid_ctl2_RadioButton");
$this->pause(800);
$this->assertText($base."Result", "You have selected Radio Button #2");
-
+
$this->click($base."grid_ctl3_RadioButton");
$this->pause(800);
$this->assertText($base."Result", "You have selected Radio Button #3");
-
+
$this->click($base."grid_ctl4_RadioButton");
$this->pause(800);
$this->assertText($base."Result", "You have selected Radio Button #4");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket719TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket719TestCase.php
index 4205427b..a984ee43 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket719TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket719TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket719TestCase extends PradoGenericSeleniumTest
+class Ticket719TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open("tickets/index.php?page=Ticket719");
- $this->verifyTextPresent("Verifying Ticket 719");
+ $this->url("tickets/index.php?page=Ticket719");
+ $this->assertTextPresent("Verifying Ticket 719");
$base="ctl0_Content_";
@@ -17,17 +17,17 @@ class Ticket719TestCase extends PradoGenericSeleniumTest
$this->type("${base}autocomplete", 'f');
$this->runScript("Prado.Registry['${base}autocomplete'].onKeyPress({})");
$this->pause(500);
- $this->verifyTextPresent('Finland');
+ $this->assertTextPresent('Finland');
$this->type("${base}autocomplete", 'fr');
$this->runScript("Prado.Registry['${base}autocomplete'].onKeyPress({})");
$this->pause(500);
- $this->verifyTextPresent('French');
+ $this->assertTextPresent('French');
$this->type("${base}autocomplete", 'fra');
$this->runScript("Prado.Registry['${base}autocomplete'].onKeyPress({})");
$this->pause(500);
- $this->verifyTextPresent('France');
+ $this->assertTextPresent('France');
$this->click("css=#${base}autocomplete_result ul li");
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Ticket722TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket722TestCase.php
index 90711162..f98214cc 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket722TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket722TestCase.php
@@ -1,28 +1,27 @@
<?php
-class Ticket722TestCase extends PradoGenericSeleniumTest
+class Ticket722TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket722');
- $this->assertTitle("Verifying Ticket 722");
-
+ $this->url('tickets/index.php?page=Ticket722');
+ $this->assertEquals($this->title(), "Verifying Ticket 722");
+
$this->assertText($base.'InPlaceTextBox__label', 'Editable Text');
$this->click($base.'InPlaceTextBox__label');
$this->pause(800);
$this->assertVisible($base.'InPlaceTextBox');
$this->type($base.'InPlaceTextBox',"Prado");
- $this->fireEvent($base.'InPlaceTextBox', 'blur'); // Release textbox
$this->pause(800);
$this->assertNotVisible($base.'InPlaceTextBox');
$this->assertText($base.'InPlaceTextBox__label', 'Prado');
$this->click($base.'ctl0');
$this->pause(800);
- $this->assertText($base.'InPlaceTextBox__label', 'exact:Prado [Read Only]');
+ $this->assertText($base.'InPlaceTextBox__label', 'Prado [Read Only]');
$this->click($base.'InPlaceTextBox__label');
$this->pause(800);
$this->assertNotVisible($base.'InPlaceTextBox');
-
+
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket72TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket72TestCase.php
index 111b7583..1a236ffa 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket72TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket72TestCase.php
@@ -1,14 +1,14 @@
<?php
-class Ticket72TestCase extends PradoGenericSeleniumTest
+class Ticket72TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket72');
+ $this->url('tickets/index.php?page=Ticket72');
$this->type("ctl0\$Content\$K1", "abc");
$this->type("ctl0\$Content\$K2", "efg");
$this->clickAndWait("//input[@type='submit' and @value='Send']", "");
- $this->verifyTextPresent("efg", "");
- $this->verifyTextNotPresent("abcefg", "");
+ $this->assertTextPresent("efg", "");
+ $this->assertTextNotPresent("abcefg", "");
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket745TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket745TestCase.php
index f822e37f..c23aa900 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket745TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket745TestCase.php
@@ -1,17 +1,17 @@
<?php
-class Ticket745TestCase extends PradoGenericSeleniumTest
+class Ticket745TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket745');
- $this->assertTitle("Verifying Ticket 745");
-
+ $this->url('tickets/index.php?page=Ticket745');
+ $this->assertEquals($this->title(), "Verifying Ticket 745");
+
$this->select($base.'Wizard1_DropDownList1', 'Green');
$this->click($base.'Wizard1_ctl4_ctl1');
$this->pause(800);
$this->assertTextPresent ('Step 3 of 3');
-
+
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket769TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket769TestCase.php
index 258a09a7..b335d148 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket769TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket769TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket769TestCase extends PradoGenericSeleniumTest
+class Ticket769TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base="ctl0_Content_";
- $this->open('tickets/index.php?page=Ticket769');
- $this->assertTitle("Verifying Ticket 769");
+ $this->url('tickets/index.php?page=Ticket769');
+ $this->assertEquals($this->title(), "Verifying Ticket 769");
$this->click($base.'ctl0');
$this->assertVisible($base.'ctl1');
@@ -15,11 +15,11 @@ class Ticket769TestCase extends PradoGenericSeleniumTest
$this->click($base.'ctl0');
$this->pause(800);
$this->assertNotVisible($base.'ctl1');
- $this->assertEquals($this->getValue($base.'ctl0'), 'T1 clicked' );
+ $this->assertValue($base.'ctl0', 'T1 clicked' );
$this->click($base.'ctl2');
$this->pause(800);
- $this->assertEquals($this->getText($base.'B'), 'This is B');
+ $this->assertText($base.'B', 'This is B');
$this->click($base.'ctl3');
$this->pause(800);
@@ -30,6 +30,6 @@ class Ticket769TestCase extends PradoGenericSeleniumTest
$this->click($base.'ctl0');
$this->pause(800);
$this->assertNotVisible($base.'ctl1');
- $this->assertEquals($this->getValue($base.'ctl0'), 'T1 clicked clicked' );
+ $this->assertValue($base.'ctl0', 'T1 clicked clicked' );
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php
index 229a68eb..7b8e7dd0 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php
@@ -1,19 +1,19 @@
<?php
-class Ticket785TestCase extends PradoGenericSeleniumTest
+class Ticket785TestCase extends PradoGenericSelenium2Test
{
function test()
{
$year=date('Y')-1;
$base = 'ctl0_Content_';
- $this->open('tickets/index.php?page=Ticket785');
- $this->assertTitle("Verifying Ticket 785");
-
+ $this->url('tickets/index.php?page=Ticket785');
+ $this->assertEquals($this->title(), "Verifying Ticket 785");
+
$this->assertText('selDate', '');
$this->select($base."datePicker_year", $year);
$this->pause(800);
$expectedDate=date("d-m").'-'.$year;
$this->assertText('selDate', $expectedDate);
-
+
$this->click($base."datePickerbutton");
$this->pause(800);
$this->click("css=input.todayButton");
@@ -21,13 +21,13 @@ class Ticket785TestCase extends PradoGenericSeleniumTest
$this->clickAt("css=body","0,0"); // Hide calendar
$expectedDate=date("d-m-Y");
$this->assertText('selDate', $expectedDate);
-
+
$this->assertText('selDate2', '');
$this->type($base.'datePicker2', '12/05/2006');
$this->pause(800);
$this->clickAt("css=body","0,0");
- $this->assertText('selDate2', '12/05/2006');
-
+ $this->assertText('selDate2', '12/05/2006');
+
}
} \ No newline at end of file
diff --git a/tests/FunctionalTests/tickets/tests/Ticket823TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket823TestCase.php
index 11e363ba..7b7a7759 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket823TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket823TestCase.php
@@ -1,12 +1,12 @@
<?php
-class Ticket823TestCase extends PradoGenericSeleniumTest {
+class Ticket823TestCase extends PradoGenericSelenium2Test {
public function test() {
- $this->open('tickets/index.php?page=Ticket823');
- $this->assertTitle("Verifying Ticket 823");
+ $this->url('tickets/index.php?page=Ticket823');
+ $this->assertEquals($this->title(), "Verifying Ticket 823");
$base = 'ctl0_Content_';
- $this->assertElementPresent('xpath=//option[@value="Choose..."]');
+ $this->assertElementPresent('xpath=//option[@value="Choose..."]');
}
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket828TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket828TestCase.php
index bbe185ad..f4d3676e 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket828TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket828TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket828TestCase extends PradoGenericSeleniumTest
+class Ticket828TestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("tickets/index.php?page=Ticket828");
+ $this->url("tickets/index.php?page=Ticket828");
$this->click("{$base}submit1");
$this->assertVisible("{$base}validator1");
$this->assertVisible("{$base}validator2");
diff --git a/tests/FunctionalTests/tickets/tests/Ticket849TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket849TestCase.php
index fef9ac31..afd826f5 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket849TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket849TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket849TestCase extends PradoGenericSeleniumTest
+class Ticket849TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket849');
- $this->assertTitle("Verifying Ticket 849");
+ $this->url('tickets/index.php?page=Ticket849');
+ $this->assertEquals($this->title(), "Verifying Ticket 849");
$base='ctl0_Content_';
$this->click($base.'ctl0');
$this->pause(800);
diff --git a/tests/FunctionalTests/tickets/tests/Ticket876TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket876TestCase.php
index 8006dd09..8d64d60d 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket876TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket876TestCase.php
@@ -1,22 +1,22 @@
<?php
-class Ticket876TestCase extends PradoGenericSeleniumTest {
+class Ticket876TestCase extends PradoGenericSelenium2Test {
public function test() {
- $this->open('tickets/index.php?page=Ticket876');
- $this->assertTitle("Verifying Ticket 876");
+ $this->url('tickets/index.php?page=Ticket876');
+ $this->assertEquals($this->title(), "Verifying Ticket 876");
$base = 'ctl0_Content_';
-
+
$this->assertElementPresent('xpath=//link[@rel="stylesheet"]');
$this->clickAndWait($base.'Button');
$this->assertElementNotPresent('xpath=//link[@rel="stylesheet"]');
-
+
/*$this->select($base.'Date_month', 10);
$this->select($base.'Date_day', 22);
-
+
$this->clickAndWait($base.'SendButton');
$this->assertTextPresent('2008-10-22');*/
}
-
+
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket886TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket886TestCase.php
index 99990ebf..820e0170 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket886TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket886TestCase.php
@@ -1,11 +1,11 @@
<?php
-class Ticket886TestCase extends PradoGenericSeleniumTest
+class Ticket886TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket886');
- $this->assertTitle("Verifying Ticket 886");
+ $this->url('tickets/index.php?page=Ticket886');
+ $this->assertEquals($this->title(), "Verifying Ticket 886");
$base = 'ctl0_Content_';
$this->clickAndWait($base.'SendButton');
$this->assertTextPresent(date('Y').'-01-01');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket897TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket897TestCase.php
index 67d1f1f2..6c49276f 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket897TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket897TestCase.php
@@ -1,16 +1,16 @@
<?php
-class Ticket897TestCase extends PradoGenericSeleniumTest
+class Ticket897TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket897');
- $this->assertTitle("Verifying Ticket 897");
+ $this->url('tickets/index.php?page=Ticket897');
+ $this->assertEquals($this->title(), "Verifying Ticket 897");
$base = 'ctl0_Content_';
-
+
$this->select($base.'Date_month', 10);
$this->select($base.'Date_day', 22);
-
+
$this->clickAndWait($base.'SendButton');
$this->assertTextPresent(date('Y').'-10-22');
}
diff --git a/tests/FunctionalTests/tickets/tests/Ticket900TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket900TestCase.php
index 3ec69873..a6f823bc 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket900TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket900TestCase.php
@@ -1,13 +1,13 @@
<?php
-class Ticket900TestCase extends PradoGenericSeleniumTest
+class Ticket900TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket900');
- $this->assertTitle("Verifying Ticket 900");
+ $this->url('tickets/index.php?page=Ticket900');
+ $this->assertEquals($this->title(), "Verifying Ticket 900");
$base = 'ctl0_Content_';
-
+
$this->clickAndWait('ctl0$Content$DataGrid$ctl1$ctl3');
$this->type($base.'DataGrid_ctl1_TextBox', '');
$this->click($base.'DataGrid_ctl1_ctl3');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket922TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket922TestCase.php
index 208bd1d0..64490f1f 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket922TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket922TestCase.php
@@ -1,13 +1,13 @@
<?php
-class Ticket922TestCase extends PradoGenericSeleniumTest
+class Ticket922TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket922');
- $this->assertTitle("Verifying Ticket 922");
+ $this->url('tickets/index.php?page=Ticket922');
+ $this->assertEquals($this->title(), "Verifying Ticket 922");
$base = 'ctl0_Content_';
-
+
$this->type($base.'Text', 'two words');
$this->clickAndWait('ctl0$Content$ctl0');
$this->assertText($base.'Result','two words');
diff --git a/tests/FunctionalTests/tickets/tests/Ticket93TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket93TestCase.php
index a56925a8..51d5b582 100755
--- a/tests/FunctionalTests/tickets/tests/Ticket93TestCase.php
+++ b/tests/FunctionalTests/tickets/tests/Ticket93TestCase.php
@@ -4,12 +4,12 @@
*
*/
-class Ticket93TestCase extends PradoGenericSeleniumTest
+class Ticket93TestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('tickets/index.php?page=Ticket93');
- $this->verifyTextPresent("ValidationGroups without any inputs with grouping");
+ $this->url('tickets/index.php?page=Ticket93');
+ $this->assertTextPresent("ValidationGroups without any inputs with grouping");
}
-
+
}
diff --git a/tests/FunctionalTests/validators/protected/pages/ListControl.page b/tests/FunctionalTests/validators/protected/pages/ListControl.page
index 1429e184..a75dc3ff 100755
--- a/tests/FunctionalTests/validators/protected/pages/ListControl.page
+++ b/tests/FunctionalTests/validators/protected/pages/ListControl.page
@@ -1,58 +1,58 @@
<com:TContent ID="Content">
- <h1>List Control Required Field Validation Test</h1>
+ <h1>List Control Required Field Validation Test</h1>
<com:TCheckBoxList ID="list1">
<com:TListItem Text="Select a color below" Value="" />
<com:TListItem Text="Red" />
<com:TListItem Text="Blue" />
<com:TListItem Text="Green" />
</com:TCheckBoxList>
-
+
<com:TRequiredFieldValidator ID="validator1"
ControlToValidate="list1"
InitialValue="Select a color below"
ErrorMessage="*" />
-
+
<hr />
-
+
<com:TDropDownList ID="list2">
<com:TListItem Text="--- Select a color ---" />
<com:TListItem Text="Red" />
<com:TListItem Text="Blue" />
<com:TListItem Text="Green" />
</com:TDropDownList>
-
+
<com:TRequiredFieldValidator ID="validator2"
ControlToValidate="list2"
InitialValue="--- Select a color ---"
ErrorMessage="*" />
-
+
<hr />
-
+
<com:TListBox ID="list3">
- <com:TListItem Text="Don't select this one" />
+ <com:TListItem Text="Dont select this one" />
<com:TListItem Text="Red" />
<com:TListItem Text="Blue" />
<com:TListItem Text="Green" />
</com:TListBox>
-
+
<com:TRequiredFieldValidator ID="validator3"
ControlToValidate="list3"
- InitialValue="Don't select this one"
+ InitialValue="Dont select this one"
ErrorMessage="*" />
-
+
<hr />
-
+
<com:TRadioButtonList ID="list4">
<com:TListItem Text="Select something else" />
<com:TListItem Text="Red" />
<com:TListItem Text="Blue" />
<com:TListItem Text="Green" />
</com:TRadioButtonList>
-
+
<com:TRequiredFieldValidator ID="validator4"
ControlToValidate="list4"
InitialValue="Select something else"
ErrorMessage="*" />
-
+
<com:TButton ID="submit1" Text="Submit!" />
</com:TContent> \ No newline at end of file
diff --git a/tests/FunctionalTests/validators/tests/ButtonTestCase.php b/tests/FunctionalTests/validators/tests/ButtonTestCase.php
index 58001322..898c6ff3 100755
--- a/tests/FunctionalTests/validators/tests/ButtonTestCase.php
+++ b/tests/FunctionalTests/validators/tests/ButtonTestCase.php
@@ -1,63 +1,63 @@
<?php
-class ButtonTestCase extends PradoGenericSeleniumTest
+class ButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('validators/index.php?page=Button');
+ $this->url('validators/index.php?page=Button');
// verify all error messages are invisible
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validator shows the error
$this->click("ctl0_Content_ctl1");
- $this->verifyVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button1 is clicked');
+ $this->assertTextNotPresent('Button1 is clicked');
$this->type("ctl0_Content_TextBox1", "test");
$this->clickAndWait("ctl0_Content_ctl1");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button1 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button1 is clicked and valid');
// verify the second validator shows the error
$this->click("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the second validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button2 is clicked');
+ $this->assertTextNotPresent('Button2 is clicked');
$this->type("ctl0_Content_TextBox2", "test");
$this->clickAndWait("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button2 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button2 is clicked and valid');
// verify the third validator shows the error
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertVisible('ctl0_Content_ctl4');
// verify the third validation is passed
- $this->verifyTextPresent('Button3 is clicked');
- $this->verifyTextNotPresent('Button3 is clicked and valid');
+ $this->assertTextPresent('Button3 is clicked');
+ $this->assertTextNotPresent('Button3 is clicked and valid');
$this->type("ctl0_Content_TextBox3", "test");
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button3 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button3 is clicked and valid');
}
}
diff --git a/tests/FunctionalTests/validators/tests/CheckBoxTestCase.php b/tests/FunctionalTests/validators/tests/CheckBoxTestCase.php
index 847cbc9a..ebcffd00 100755
--- a/tests/FunctionalTests/validators/tests/CheckBoxTestCase.php
+++ b/tests/FunctionalTests/validators/tests/CheckBoxTestCase.php
@@ -1,65 +1,65 @@
<?php
-class CheckBoxTestCase extends PradoGenericSeleniumTest
+class CheckBoxTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('validators/index.php?page=CheckBox');
+ $this->url('validators/index.php?page=CheckBox');
// verify all error messages are invisible
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validator shows the error
$this->click("ctl0_Content_ctl1");
- $this->verifyVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button1 is clicked');
+ $this->assertTextNotPresent('Button1 is clicked');
$this->type("ctl0_Content_TextBox1", "test");
$this->clickAndWait("ctl0_Content_ctl1");
$this->clickAndWait("ctl0_Content_ctl1");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button1 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button1 is clicked and valid');
// verify the second validator shows the error
$this->click("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the second validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button2 is clicked');
+ $this->assertTextNotPresent('Button2 is clicked');
$this->type("ctl0_Content_TextBox2", "test");
$this->clickAndWait("ctl0_Content_ctl3");
$this->clickAndWait("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button2 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button2 is clicked and valid');
// verify the third validator shows the error
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertVisible('ctl0_Content_ctl4');
// verify the third validation is passed
- $this->verifyTextPresent('Button3 is clicked');
- $this->verifyTextNotPresent('Button3 is clicked and valid');
+ $this->assertTextPresent('Button3 is clicked');
+ $this->assertTextNotPresent('Button3 is clicked and valid');
$this->type("ctl0_Content_TextBox3", "test");
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button3 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button3 is clicked and valid');
}
}
diff --git a/tests/FunctionalTests/validators/tests/CompareValidatorTestCase.php b/tests/FunctionalTests/validators/tests/CompareValidatorTestCase.php
index 0c18f43b..c4985407 100755
--- a/tests/FunctionalTests/validators/tests/CompareValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/CompareValidatorTestCase.php
@@ -1,19 +1,19 @@
<?php
//New Test
-class CompareValidatorTestCase extends PradoGenericSeleniumTest
+class CompareValidatorTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
-
- $this->open("validators/index.php?page=CompareValidator", "");
- $this->verifyTextPresent("Prado CompareValidator Tests", "");
+
+ $this->url("validators/index.php?page=CompareValidator");
+ $this->assertTextPresent("Prado CompareValidator Tests", "");
$this->type("{$base}text1", "qwe");
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
-
+
$this->click("//input[@type='submit' and @value='Test']", "");
$this->type("{$base}text2", "1234");
@@ -24,20 +24,20 @@ class CompareValidatorTestCase extends PradoGenericSeleniumTest
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
-
+
$this->type("{$base}text3", "12312");
$this->click("//input[@type='submit' and @value='Test']", "");
$this->pause(500);
$this->assertVisible("{$base}validator2");
-
+
$this->type("{$base}text3", "13/1/2005");
$this->assertVisible("{$base}validator2");
-
+
$this->type("{$base}text3", "12/1/2005");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
-
+
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
diff --git a/tests/FunctionalTests/validators/tests/ConditionalValidationTestCase.php b/tests/FunctionalTests/validators/tests/ConditionalValidationTestCase.php
index 02b174ef..d9981eb8 100755
--- a/tests/FunctionalTests/validators/tests/ConditionalValidationTestCase.php
+++ b/tests/FunctionalTests/validators/tests/ConditionalValidationTestCase.php
@@ -1,12 +1,12 @@
<?php
-class ConditionalValidationTestCase extends PradoGenericSeleniumTest
+class ConditionalValidationTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=ConditionalValidation", "");
- $this->verifyTextPresent("Conditional Validation (clientside + server side)", "");
+ $this->url("validators/index.php?page=ConditionalValidation");
+ $this->assertTextPresent("Conditional Validation (clientside + server side)", "");
$this->assertNotVisible("{$base}validator1", "");
$this->assertNotVisible("{$base}validator2", "");
diff --git a/tests/FunctionalTests/validators/tests/CustomValidatorTestCase.php b/tests/FunctionalTests/validators/tests/CustomValidatorTestCase.php
index 106f7a00..c7bb6f9c 100755
--- a/tests/FunctionalTests/validators/tests/CustomValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/CustomValidatorTestCase.php
@@ -1,18 +1,18 @@
<?php
//New Test
-class CustomValidatorTestCase extends PradoGenericSeleniumTest
+class CustomValidatorTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=CustomValidator", "");
+ $this->url("validators/index.php?page=CustomValidator");
$this->assertTextPresent("Prado CustomValidator Tests", "");
$this->assertNotVisible("{$base}validator1");
$this->click("//input[@type='submit' and @value='Test']", "");
$this->assertVisible("{$base}validator1");
-
+
$this->type("{$base}text1", "Prado");
$this->pause(250);
$this->assertNotVisible("{$base}validator1");
diff --git a/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php b/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
index 58a74fe4..f037b5e4 100755
--- a/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/DataTypeValidatorTestCase.php
@@ -3,16 +3,16 @@
* Created on 25/04/2006
*/
-class DataTypeValidatorTestCase extends PradoGenericSeleniumTest
+class DataTypeValidatorTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=DataTypeValidator", "");
- $this->verifyTextPresent("Data Type Validator Tests", "");
+ $this->url("validators/index.php?page=DataTypeValidator");
+ $this->assertTextPresent("Data Type Validator Tests", "");
$this->click("//input[@type='submit' and @value='submit!']", "");
$this->pause(500);
-
+
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
$this->assertNotVisible("{$base}validator3");
@@ -26,26 +26,26 @@ class DataTypeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertVisible("{$base}validator1");
$this->assertVisible("{$base}validator2");
$this->assertVisible("{$base}validator3");
-
+
$this->type("{$base}textbox1", "12");
$this->type("{$base}textbox2", "12.5");
$this->type("{$base}textbox3", "2/10/2005");
$this->clickAndWait("//input[@type='submit' and @value='submit!']", "");
-
+
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
$this->assertNotVisible("{$base}validator3");
-
+
$this->type("{$base}textbox1", "12.2");
$this->type("{$base}textbox2", "-12.5");
$this->type("{$base}textbox3", "2/13/2005");
$this->click("//input[@type='submit' and @value='submit!']", "");
$this->pause(500);
-
+
$this->assertVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
$this->assertVisible("{$base}validator3");
}
-
-}
+
+}
diff --git a/tests/FunctionalTests/validators/tests/DatePickerTestCase.php b/tests/FunctionalTests/validators/tests/DatePickerTestCase.php
index bbefd2a7..1768d244 100755
--- a/tests/FunctionalTests/validators/tests/DatePickerTestCase.php
+++ b/tests/FunctionalTests/validators/tests/DatePickerTestCase.php
@@ -1,14 +1,14 @@
<?php
-class DatePickerTestCase extends PradoGenericSeleniumTest
+class DatePickerTestCase extends PradoGenericSelenium2Test
{
function test()
{
$year=2012;
$year2=2013;
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=DatePicker", "");
- $this->verifyTextPresent("Date Picker validation Test", "");
+ $this->url("validators/index.php?page=DatePicker");
+ $this->assertTextPresent("Date Picker validation Test", "");
$this->assertNotVisible("{$base}validator1", "");
$this->assertNotVisible("{$base}validator2", "");
$this->assertNotVisible("{$base}validator4", "");
diff --git a/tests/FunctionalTests/validators/tests/ImageButtonTestCase.php b/tests/FunctionalTests/validators/tests/ImageButtonTestCase.php
index e6b5d6d8..ef086baa 100755
--- a/tests/FunctionalTests/validators/tests/ImageButtonTestCase.php
+++ b/tests/FunctionalTests/validators/tests/ImageButtonTestCase.php
@@ -1,63 +1,63 @@
<?php
-class ImageButtonTestCase extends PradoGenericSeleniumTest
+class ImageButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('validators/index.php?page=ImageButton');
+ $this->url('validators/index.php?page=ImageButton');
// verify all error messages are invisible
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validator shows the error
$this->click("ctl0_Content_ctl1");
- $this->verifyVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button1 is clicked');
+ $this->assertTextNotPresent('Button1 is clicked');
$this->type("ctl0_Content_TextBox1", "test");
$this->clickAndWait("ctl0_Content_ctl1");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button1 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button1 is clicked and valid');
// verify the second validator shows the error
$this->click("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the second validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button2 is clicked');
+ $this->assertTextNotPresent('Button2 is clicked');
$this->type("ctl0_Content_TextBox2", "test");
$this->clickAndWait("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button2 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button2 is clicked and valid');
// verify the third validator shows the error
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertVisible('ctl0_Content_ctl4');
// verify the third validation is passed
- $this->verifyTextPresent('Button3 is clicked');
- $this->verifyTextNotPresent('Button3 is clicked and valid');
+ $this->assertTextPresent('Button3 is clicked');
+ $this->assertTextNotPresent('Button3 is clicked and valid');
$this->type("ctl0_Content_TextBox3", "test");
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button3 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button3 is clicked and valid');
}
}
diff --git a/tests/FunctionalTests/validators/tests/LinkButtonTestCase.php b/tests/FunctionalTests/validators/tests/LinkButtonTestCase.php
index b523452c..66e2fc61 100755
--- a/tests/FunctionalTests/validators/tests/LinkButtonTestCase.php
+++ b/tests/FunctionalTests/validators/tests/LinkButtonTestCase.php
@@ -1,62 +1,62 @@
<?php
-class LinkButtonTestCase extends PradoGenericSeleniumTest
+class LinkButtonTestCase extends PradoGenericSelenium2Test
{
function test()
{
- $this->open('validators/index.php?page=LinkButton');
+ $this->url('validators/index.php?page=LinkButton');
// verify all error messages are invisible
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validator shows the error
$this->click("ctl0_Content_ctl1");
- $this->verifyVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the first validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button1 is clicked');
+ $this->assertTextNotPresent('Button1 is clicked');
$this->type("ctl0_Content_TextBox1", "test");
$this->clickAndWait("ctl0_Content_ctl1");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button1 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button1 is clicked and valid');
// verify the second validator shows the error
$this->click("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
// verify the second validation is passed
$this->pause(500);
- $this->verifyTextNotPresent('Button2 is clicked');
+ $this->assertTextNotPresent('Button2 is clicked');
$this->type("ctl0_Content_TextBox2", "test");
$this->clickAndWait("ctl0_Content_ctl3");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button2 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button2 is clicked and valid');
// verify the third validator shows the error
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyVisible('ctl0_Content_ctl4');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertVisible('ctl0_Content_ctl4');
// verify the third validation is passed
- $this->verifyTextPresent('Button3 is clicked');
- $this->verifyTextNotPresent('Button3 is clicked and valid');
+ $this->assertTextPresent('Button3 is clicked');
+ $this->assertTextNotPresent('Button3 is clicked and valid');
$this->type("ctl0_Content_TextBox3", "test");
$this->clickAndWait("ctl0_Content_ctl5");
- $this->verifyNotVisible('ctl0_Content_ctl0');
- $this->verifyNotVisible('ctl0_Content_ctl2');
- $this->verifyNotVisible('ctl0_Content_ctl4');
- $this->verifyTextPresent('Button3 is clicked and valid');
+ $this->assertNotVisible('ctl0_Content_ctl0');
+ $this->assertNotVisible('ctl0_Content_ctl2');
+ $this->assertNotVisible('ctl0_Content_ctl4');
+ $this->assertTextPresent('Button3 is clicked and valid');
}
}
diff --git a/tests/FunctionalTests/validators/tests/ListControlTestCase.php b/tests/FunctionalTests/validators/tests/ListControlTestCase.php
index 68feee84..a8aca64b 100755
--- a/tests/FunctionalTests/validators/tests/ListControlTestCase.php
+++ b/tests/FunctionalTests/validators/tests/ListControlTestCase.php
@@ -3,13 +3,13 @@
* Created on 24/04/2006
*/
-class ListControlTestCase extends PradoGenericSeleniumTest
+class ListControlTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=ListControl", "");
- $this->verifyTextPresent("List Control Required Field Validation Test", "");
+ $this->url("validators/index.php?page=ListControl");
+ $this->assertTextPresent("List Control Required Field Validation Test", "");
$this->click("//input[@type='submit' and @value='Submit!']", "");
$this->assertVisible("{$base}validator1");
@@ -28,7 +28,8 @@ class ListControlTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator3");
$this->assertNotVisible("{$base}validator4");
- $this->select("{$base}list3", "label=Don't select this one");
+ //invalid selector: Unable to locate an element with the xpath expression .//option[.='Don\'t select this one'] because of the following error: SyntaxError: Failed to execute 'evaluate' on 'Document': The string './/option[.='Don\'t select this one']' is not a valid XPath expression.
+ $this->select("{$base}list3", "label=Dont select this one");
$this->click("{$base}list4_c0");
$this->select("{$base}list2", "label=--- Select a color ---");
$this->click("//input[@type='submit' and @value='Submit!']", "");
diff --git a/tests/FunctionalTests/validators/tests/RangeValidatorTestCase.php b/tests/FunctionalTests/validators/tests/RangeValidatorTestCase.php
index 022ee7f6..668260ad 100755
--- a/tests/FunctionalTests/validators/tests/RangeValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/RangeValidatorTestCase.php
@@ -1,14 +1,14 @@
<?php
//New Test
-class RangeValidatorTestCase extends PradoGenericSeleniumTest
+class RangeValidatorTestCase extends PradoGenericSelenium2Test
{
function testIntegerRange()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RangeValidatorInteger", "");
- $this->verifyTextPresent("Prado RangeValidator Tests Integer", "");
-
+ $this->url("validators/index.php?page=RangeValidatorInteger");
+ $this->assertTextPresent("Prado RangeValidator Tests Integer", "");
+
//between 1 and 4
$this->type("{$base}text1", "ad");
$this->assertNotVisible("{$base}validator1", "");
@@ -21,8 +21,8 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator1", "");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator1", "");
-
-
+
+
// >= 2
$this->assertNotVisible("{$base}validator2", "");
$this->type("{$base}text2", "1");
@@ -42,13 +42,13 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator3", "");
}
-
+
function testFloatRange()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RangeValidatorFloat", "");
- $this->verifyTextPresent("Prado RangeValidator Tests Float", "");
-
+ $this->url("validators/index.php?page=RangeValidatorFloat");
+ $this->assertTextPresent("Prado RangeValidator Tests Float", "");
+
//between 1 and 4
$this->type("{$base}text1", "ad");
$this->assertNotVisible("{$base}validator1", "");
@@ -61,8 +61,8 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator1", "");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator1", "");
-
-
+
+
// >= 2
$this->assertNotVisible("{$base}validator2", "");
$this->type("{$base}text2", "1");
@@ -81,13 +81,13 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator3", "");
}
-
+
function testDateRange()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RangeValidatorDate", "");
- $this->verifyTextPresent("Prado RangeValidator Tests Date", "");
-
+ $this->url("validators/index.php?page=RangeValidatorDate");
+ $this->assertTextPresent("Prado RangeValidator Tests Date", "");
+
//between 22/1/2005 and 3/2/2005
$this->type("{$base}text1", "ad");
$this->assertNotVisible("{$base}validator1", "");
@@ -101,8 +101,8 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator1", "");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator1", "");
-
-
+
+
// >= 22/1/2005
$this->assertNotVisible("{$base}validator2", "");
$this->type("{$base}text2", "1/1/2005");
@@ -122,14 +122,14 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->type("{$base}text3", "1/2/2005");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator3", "");
- }
-
+ }
+
function testStringRange()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RangeValidatorString", "");
- $this->verifyTextPresent("Prado RangeValidator Tests String", "");
-
+ $this->url("validators/index.php?page=RangeValidatorString");
+ $this->assertTextPresent("Prado RangeValidator Tests String", "");
+
//between 'd' and 'y'
$this->type("{$base}text1", "a");
$this->assertNotVisible("{$base}validator1", "");
@@ -142,8 +142,8 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->assertNotVisible("{$base}validator1", "");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator1", "");
-
-
+
+
// >= 'd'
$this->assertNotVisible("{$base}validator2", "");
$this->type("{$base}text2", "a");
@@ -161,6 +161,6 @@ class RangeValidatorTestCase extends PradoGenericSeleniumTest
$this->type("{$base}text3", "t");
$this->clickAndWait("//input[@type='submit' and @value='Test']", "");
$this->assertNotVisible("{$base}validator3", "");
- }
+ }
}
diff --git a/tests/FunctionalTests/validators/tests/RegExpValidatorTestCase.php b/tests/FunctionalTests/validators/tests/RegExpValidatorTestCase.php
index f269bf3b..b45ebcf3 100755
--- a/tests/FunctionalTests/validators/tests/RegExpValidatorTestCase.php
+++ b/tests/FunctionalTests/validators/tests/RegExpValidatorTestCase.php
@@ -1,13 +1,13 @@
<?php
//New Test
-class RegExpValidatorTestCase extends PradoGenericSeleniumTest
+class RegExpValidatorTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RegularExpressionValidator", "");
- $this->verifyTextPresent("Prado RegularExpressionValidator Tests", "");
+ $this->url("validators/index.php?page=RegularExpressionValidator");
+ $this->assertTextPresent("Prado RegularExpressionValidator Tests", "");
$this->assertNotVisible("{$base}validator1", "");
$this->assertNotVisible("{$base}validator2", "");
$this->type("{$base}text1", "1");
diff --git a/tests/FunctionalTests/validators/tests/RequiredFieldTestCase.php b/tests/FunctionalTests/validators/tests/RequiredFieldTestCase.php
index 50c73384..6cf79611 100755
--- a/tests/FunctionalTests/validators/tests/RequiredFieldTestCase.php
+++ b/tests/FunctionalTests/validators/tests/RequiredFieldTestCase.php
@@ -1,11 +1,11 @@
<?php
-class RequiredFieldTestCase extends PradoGenericSeleniumTest
+class RequiredFieldTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RequiredFieldValidator");
+ $this->url("validators/index.php?page=RequiredFieldValidator");
$this->assertTextPresent("RequiredFieldValidator Tests");
$this->assertNotVisible("{$base}validator1");
$this->assertNotVisible("{$base}validator2");
@@ -73,7 +73,7 @@ class RequiredFieldTestCase extends PradoGenericSeleniumTest
function testInitialValue()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RequiredFieldValidator");
+ $this->url("validators/index.php?page=RequiredFieldValidator");
$this->assertTextPresent("InitialValue Test");
$this->assertNotVisible("{$base}validator9");
$this->click("{$base}submit5");
diff --git a/tests/FunctionalTests/validators/tests/RequiredListTestCase.php b/tests/FunctionalTests/validators/tests/RequiredListTestCase.php
index 2662c721..6fbb1905 100755
--- a/tests/FunctionalTests/validators/tests/RequiredListTestCase.php
+++ b/tests/FunctionalTests/validators/tests/RequiredListTestCase.php
@@ -1,12 +1,12 @@
<?php
-class RequiredListTestCase extends PradoGenericSeleniumTest
+class RequiredListTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
- $this->open("validators/index.php?page=RequiredListValidator");
+ $this->url("validators/index.php?page=RequiredListValidator");
$this->click("{$base}submit1");
$this->assertVisible("{$base}validator1");
$this->assertVisible("{$base}validator2");
diff --git a/tests/FunctionalTests/validators/tests/ValidationSummaryTestCase.php b/tests/FunctionalTests/validators/tests/ValidationSummaryTestCase.php
index 7dc1d6b1..0ee8c27c 100755
--- a/tests/FunctionalTests/validators/tests/ValidationSummaryTestCase.php
+++ b/tests/FunctionalTests/validators/tests/ValidationSummaryTestCase.php
@@ -1,46 +1,46 @@
<?php
//New Test
-class ValidationSummaryTestCase extends PradoGenericSeleniumTest
+class ValidationSummaryTestCase extends PradoGenericSelenium2Test
{
function test()
{
$base = "ctl0_Content_";
-
- $this->open("validators/index.php?page=ValidationSummary", "");
- $this->verifyTextPresent("Validation Summary Test", "");
- //$this->verifyText("{$base}summary1", "");
- //$this->verifyText("{$base}summary2", "");
-
+
+ $this->url("validators/index.php?page=ValidationSummary");
+ $this->assertTextPresent("Validation Summary Test", "");
+ //$this->assertText("{$base}summary1", "");
+ //$this->assertText("{$base}summary2", "");
+
$this->click("//input[@type='submit' and @value='Create New Account']", "");
$this->assertVisible("{$base}summary1");
$this->assertNotVisible("{$base}summary2");
$this->click("//input[@type='submit' and @value='Sign In']", "");
$this->assertNotVisible("{$base}summary1");
- $this->assertVisible("{$base}summary2");
-
+ $this->assertVisible("{$base}summary2");
+
$this->type("{$base}Username", "qwe");
$this->type("{$base}Password", "ewwq");
$this->click("//input[@type='submit' and @value='Sign In']", "");
$this->assertNotVisible("{$base}summary1");
- $this->assertVisible("{$base}summary2");
-
- /*$this->clickAndWait("//input[@type='submit' and @value='Create New Account']", "");
+ $this->assertVisible("{$base}summary2");
+
+ /*$this->clickAndWait("//input[@type='submit' and @value='Create New Account']", "");
$this->type("{$base}UserID", "123");
$this->type("{$base}Pass", "123");
$this->clickAndWait("//input[@type='submit' and @value='Sign In']", "");
- //$this->verifyText("{$base}summary1", "");
- //$this->verifyText("{$base}summary2", "");
+ //$this->assertText("{$base}summary1", "");
+ //$this->assertText("{$base}summary2", "");
$this->clickAndWait("//input[@type='submit' and @value='Create New Account']", "");
- //$this->verifyText("{$base}summary1", "");
- //$this->verifyText("{$base}summary2", "");
+ //$this->assertText("{$base}summary1", "");
+ //$this->assertText("{$base}summary2", "");
$this->type("{$base}Password", "");
$this->click("//input[@type='submit' and @value='Create New Account']", "");
$this->assertVisible("{$base}summary1");
$this->assertNotVisible("{$base}summary2");
-
+
$this->type("{$base}Password", "12312");
$this->assertVisible("{$base}summary1");
*/