diff options
Diffstat (limited to 'tests')
5 files changed, 71 insertions, 2 deletions
diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket518.page b/tests/FunctionalTests/tickets/protected/pages/Ticket518.page new file mode 100644 index 00000000..657dc4cf --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket518.page @@ -0,0 +1,10 @@ +<com:TContent ID="Content">
+<h2 class="defect">Not possible to add custom buttons to TinyMCE</h2>
+
+<com:THtmlArea>
+ <prop:Options>
+ theme_advanced_buttons3: 'justifyleft,justifycenter'
+ </prop:Options>
+</com:THtmlArea>
+
+</com:TContent>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket521.page b/tests/FunctionalTests/tickets/protected/pages/Ticket521.page new file mode 100644 index 00000000..e1f65663 --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket521.page @@ -0,0 +1,12 @@ +<com:TContent ID="Content">
+
+<!--
+ <com:System.Web.UI.ActiveControls.TActiveButton ID="addInvestType" Text="Add"
+ OnCallback="doSave" />
+-->
+<com:System.Web.UI.ActiveControls.TActiveButton id="button1" OnClick="doOnClick" OnCallback="doSave" Text="Save" />
+<com:System.Web.UI.ActiveControls.TActiveLabel ID="label1" Text="Label 1" />
+
+
+
+</com:TContent>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/protected/pages/Ticket521.php b/tests/FunctionalTests/tickets/protected/pages/Ticket521.php new file mode 100644 index 00000000..d28a777a --- /dev/null +++ b/tests/FunctionalTests/tickets/protected/pages/Ticket521.php @@ -0,0 +1,16 @@ +<?php
+
+class Ticket521 extends TPage
+{
+
+ public function doOnClick($s, $p){
+ $this->label1->Text = "Button 1 was clicked ";
+ }
+ public function doSave($s, $p){
+ $this->label1->Text .= " on callback ";
+
+ }
+
+
+}
+?>
\ No newline at end of file diff --git a/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php b/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php new file mode 100644 index 00000000..ea9feae8 --- /dev/null +++ b/tests/FunctionalTests/tickets/tests/Ticket521TestCase.php @@ -0,0 +1,20 @@ +<?php
+
+class Ticket521TestCase extends SeleniumTestCase
+{
+ function test()
+ {
+ $base = 'ctl0_Content_';
+ $this->open("tickets/index.php?page=Ticket521");
+ $this->assertTitle("Verifying Ticket 521");
+ $this->assertText("{$base}label1", "Label 1");
+
+ $this->click("{$base}button1");
+ $this->pause(1200);
+
+ $this->assertText("{$base}label1", "Button 1 was clicked on callback");
+ }
+
+}
+
+?>
\ No newline at end of file diff --git a/tests/simple_unit/ActiveRecord/ActiveRecordDynamicCallTestCase.php b/tests/simple_unit/ActiveRecord/ActiveRecordDynamicCallTestCase.php index 8f8868e9..75bbb2a4 100644 --- a/tests/simple_unit/ActiveRecord/ActiveRecordDynamicCallTestCase.php +++ b/tests/simple_unit/ActiveRecord/ActiveRecordDynamicCallTestCase.php @@ -1,5 +1,4 @@ -<?php -
+<?php
Prado::using('System.Data.ActiveRecord.TActiveRecord');
require_once(dirname(__FILE__).'/records/DepartmentRecord.php');
require_once(dirname(__FILE__).'/records/DepSections.php');
@@ -47,6 +46,18 @@ class ActiveRecordDynamicCallTestCase extends UnitTestCase $this->assertNotNull($rs);
}
+ function test_dynamic_delete_by()
+ {
+ $finder = DepartmentRecord::finder();
+ //$finder->RecordManager->OnDelete[] = array($this, 'assertDeleteSql');
+ $this->assertEqual($finder->deleteByName('tasds'), 0);
+ }
+
+ function assertDeleteSql($sender, $param)
+ {
+ var_dump($param);
+ }
+
}
?>
\ No newline at end of file |