diff options
author | tof <> | 2008-02-05 14:26:24 +0000 |
---|---|---|
committer | tof <> | 2008-02-05 14:26:24 +0000 |
commit | 4cf602da9d7cd37e49d7e645f49605e141eb05fb (patch) | |
tree | d9a09353ce69ae6e823644ae105ef40a2554879a /tests | |
parent | 515beaea9b54627f33f58debfc8619be085f8d81 (diff) |
Fixed #785
Diffstat (limited to 'tests')
3 files changed, 60 insertions, 0 deletions
diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket785.page b/tests/FunctionalTests/tickets/protected/pages/Ticket785.page new file mode 100644 index 00000000..1b402a17 --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket785.page @@ -0,0 +1,20 @@ +<com:TContent ID="Content">
+<com:TDatePicker Id="datePicker" InputMode="DropDownList"> + <prop:ClientSide.OnDateChanged> + $('selDate').innerHTML=parameter; + </prop:ClientSide.OnDateChanged> +</com:TDatePicker> +<p> +Client Side Selected date : <span id="selDate"></span> +</p> + + +<com:TDatePicker Id="datePicker2" InputMode="TextBox" DateFormat="MM/dd/yyyy" Date="12/01/20007" > + <prop:ClientSide.OnDateChanged> + $('selDate2').innerHTML=parameter; + </prop:ClientSide.OnDateChanged> +</com:TDatePicker> +<p> +Client Side Selected date : <span id="selDate2"></span> +</p>
+</com:TContent>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket785.php b/tests/FunctionalTests/tickets/protected/pages/Ticket785.php new file mode 100644 index 00000000..91ba918d --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket785.php @@ -0,0 +1,7 @@ +<?php + +class Ticket785 extends TPage +{ + +} +?>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php new file mode 100644 index 00000000..53851f7a --- /dev/null +++ b/tests/FunctionalTests/tickets/tests/Ticket785TestCase.php @@ -0,0 +1,33 @@ +<?php +class Ticket785TestCase extends SeleniumTestCase +{ + function test() + { + $base = 'ctl0_Content_'; + $this->open('tickets/index.php?page=Ticket785'); + $this->assertTitle("Verifying Ticket 785"); + + $this->assertText('selDate', ''); + $this->select($base."datePicker_year", "2007"); + $this->pause(800); + $expectedDate=date("d-m").'-2007'; + $this->assertText('selDate', $expectedDate); + + $this->click($base."datePickerbutton"); + $this->pause(800); + $this->click("css=input.todayButton"); + $this->pause(800); + $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'); + + } + +} +?>
\ No newline at end of file |