diff options
-rw-r--r-- | .gitattributes | 1 | ||||
-rw-r--r-- | tests/FunctionalTests/tickets/protected/pages/Ticket656.page | 7 | ||||
-rw-r--r-- | tests/FunctionalTests/tickets/protected/pages/Ticket656.php | 9 | ||||
-rw-r--r-- | tests/FunctionalTests/tickets/tests/Ticket656TestCase.php | 25 |
4 files changed, 42 insertions, 0 deletions
diff --git a/.gitattributes b/.gitattributes index a6faa87c..b52213d8 100644 --- a/.gitattributes +++ b/.gitattributes @@ -2624,6 +2624,7 @@ tests/FunctionalTests/tickets/protected/pages/Ticket614.page -text tests/FunctionalTests/tickets/protected/pages/Ticket617.page -text tests/FunctionalTests/tickets/protected/pages/Ticket653/Layout.tpl -text tests/FunctionalTests/tickets/protected/pages/Ticket653/ticket653.page -text +tests/FunctionalTests/tickets/protected/pages/Ticket656.page -text tests/FunctionalTests/tickets/protected/pages/Ticket659.page -text tests/FunctionalTests/tickets/protected/pages/Ticket68.page -text tests/FunctionalTests/tickets/protected/pages/Ticket72.page -text diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket656.page b/tests/FunctionalTests/tickets/protected/pages/Ticket656.page new file mode 100644 index 00000000..aa5d11b2 --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket656.page @@ -0,0 +1,7 @@ +<com:TContent ID="Content"> + +<com:TDatePicker Id="datePicker" InputMode="DropDownList"/> + +<com:System.Web.UI.ActiveControls.TActiveLabel id="lblStatus"/> +<com:System.Web.UI.ActiveControls.TActiveButton id="btnUpdate" Text="Update" OnClick="updateLbl"/> +</com:TContent>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket656.php b/tests/FunctionalTests/tickets/protected/pages/Ticket656.php new file mode 100644 index 00000000..943908c9 --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket656.php @@ -0,0 +1,9 @@ +<?php +class Ticket656 extends TPage +{ + public function updateLbl ($sender,$param) + { + $this->lblStatus->setText($this->datePicker->getDate()); + } +} +?>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php new file mode 100644 index 00000000..df77334b --- /dev/null +++ b/tests/FunctionalTests/tickets/tests/Ticket656TestCase.php @@ -0,0 +1,25 @@ +<?php +class Ticket656TestCase extends SeleniumTestCase +{ + function test() + { + $base = 'ctl0_Content_'; + $this->open('tickets/index.php?page=Ticket656'); + $this->assertTitle("Verifying Ticket 656"); + + // First test, current date + $this->click($base."btnUpdate"); + $this->pause(800); + $this->assertText($base."lblStatus",date("d-m-Y")); + + // Then, set another date + $this->select($base."datePicker_day",20); + $this->select($base."datePicker_month", 10); + $this->select($base."datePicker_year", 2008); + $this->click($base."btnUpdate"); + $this->pause(800); + $this->assertText($base."lblStatus",date("d-m-Y", mktime(0,0,0,10,20,2008))); + } + +} +?>
\ No newline at end of file |