diff options
author | wei <> | 2006-02-02 05:04:50 +0000 |
---|---|---|
committer | wei <> | 2006-02-02 05:04:50 +0000 |
commit | a2a030c3cfbb0249762fffa4159107bc13f8952d (patch) | |
tree | e8b2f97068cf92a314df360ccf8dfb1d37b92bd6 /tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php | |
parent | 93f6933c39b2e1896ff781a8f839a3c73a7e56b1 (diff) |
Fixed #19
Diffstat (limited to 'tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php')
-rw-r--r-- | tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php b/tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php new file mode 100644 index 00000000..3d9fc840 --- /dev/null +++ b/tests/FunctionalTests/protected/pages/UI/testOnClickAttribute.php @@ -0,0 +1,36 @@ +<?php
+
+/**
+ * testOnClickAttribute
+ *
+ * @author Wei Zhuo <weizhuo[at]gmail[dot]com>
+ * @version $Revision: $ $Date: $
+ * @package System.Web.UI.WebControls
+ * @since 3.0
+ */
+class testOnClickAttribute extends TPage
+{
+ function doClick()
+ {
+ $this->clickState->setText("Post Back clicked!");
+ }
+}
+
+class OnClickAttributeTestCase extends SeleniumTestCase
+{
+ function test()
+ {
+ $page = Prado::getApplication()->getTestPage(__FILE__);
+ $this->open($page);
+ $this->assertTitle("Test Attributes.OnClick");
+ $this->click("link=Click me");
+ $this->assertConfirmation("Are you sure?");
+ $this->chooseCancelOnNextConfirmation();
+ $this->assertTextNotPresent("Post Back clicked!");
+ $this->clickAndWait("link=Click me");
+ $this->assertConfirmation("Are you sure?");
+ $this->assertTextPresent("Post Back clicked!");
+ }
+}
+
+?>
\ No newline at end of file |