summaryrefslogtreecommitdiff
path: root/tests/unit/Web/UI
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/Web/UI')
-rw-r--r--tests/unit/Web/UI/AllTests.php47
-rw-r--r--tests/unit/Web/UI/TControlAdapterTest.php60
-rw-r--r--tests/unit/Web/UI/TControlTest.php280
-rw-r--r--tests/unit/Web/UI/TFormTest.php36
-rw-r--r--tests/unit/Web/UI/TPageTest.php195
5 files changed, 618 insertions, 0 deletions
diff --git a/tests/unit/Web/UI/AllTests.php b/tests/unit/Web/UI/AllTests.php
new file mode 100644
index 00000000..177852b3
--- /dev/null
+++ b/tests/unit/Web/UI/AllTests.php
@@ -0,0 +1,47 @@
+<?php
+require_once dirname(__FILE__).'/../../phpunit.php';
+
+if(!defined('PHPUnit_MAIN_METHOD')) {
+ define('PHPUnit_MAIN_METHOD', 'Web_UI_AllTests::main');
+}
+
+require_once 'TClientScriptManagerTest.php';
+require_once 'TControlAdapterTest.php';
+require_once 'TControlTest.php';
+require_once 'TFormTest.php';
+require_once 'TPageTest.php';
+/*require_once 'TTemplateControlTest.php';
+require_once 'TTemplateManagerTest.php';
+require_once 'TThemeManagerTest.php';
+require_once 'THtmlWriterTest.php';
+require_once 'TPageStatePersisterTest.php';
+require_once 'TSessionPageStatePersisterTest.php';*/
+
+class Web_UI_AllTests {
+ public static function main() {
+ PHPUnit_TextUI_TestRunner::run(self::suite());
+ }
+
+ public static function suite() {
+ $suite = new PHPUnit_Framework_TestSuite('System.Web.UI');
+
+ $suite->addTestSuite('TClientScriptManagerTest');
+ $suite->addTestSuite('TControlAdapterTest');
+ $suite->addTestSuite('TControlTest');
+ $suite->addTestSuite('TFormTest');
+ $suite->addTestSuite('TPageTest');
+ /*$suite->addTestSuite('TTemplateControlTest');
+ $suite->addTestSuite('TTemplateManagerTest');
+ $suite->addTestSuite('TThemeManagerTest');
+ $suite->addTestSuite('THtmlWriterTest');
+ $suite->addTestSuite('TPageStatePersisterTest');
+ $suite->addTestSuite('TSessionPageStatePersisterTest');*/
+
+ return $suite;
+ }
+}
+
+if(PHPUnit_MAIN_METHOD == 'Web_UI_AllTests::main') {
+ Web_UI_AllTests::main();
+}
+?>
diff --git a/tests/unit/Web/UI/TControlAdapterTest.php b/tests/unit/Web/UI/TControlAdapterTest.php
new file mode 100644
index 00000000..9ae20a49
--- /dev/null
+++ b/tests/unit/Web/UI/TControlAdapterTest.php
@@ -0,0 +1,60 @@
+<?php
+require_once dirname(__FILE__).'/../../phpunit.php';
+
+Prado::using('System.Web.UI.TControlAdapter');
+
+/**
+ * @package System.Web.UI
+ */
+class TControlAdapterTest extends PHPUnit_Framework_TestCase {
+
+ public function testConstruct() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetPage() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testCreateChildControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testLoadState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSaveState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnInit() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnLoad() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnPreRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnUnload() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRenderChildren() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+}
+?> \ No newline at end of file
diff --git a/tests/unit/Web/UI/TControlTest.php b/tests/unit/Web/UI/TControlTest.php
new file mode 100644
index 00000000..9597c23e
--- /dev/null
+++ b/tests/unit/Web/UI/TControlTest.php
@@ -0,0 +1,280 @@
+<?php
+require_once dirname(__FILE__).'/../../phpunit.php';
+
+Prado::using('System.Web.UI.TControl');
+
+/**
+ * @package System.Web.UI
+ */
+class TControlTest extends PHPUnit_Framework_TestCase {
+
+ public function testConstruct() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function test__get() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasAdapter() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetAdapter() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetParent() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetNamingContainer() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetPage() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetTemplateControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetSourceTemplateControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetControlStage() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetID() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetUniqueID() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testFocus() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetClientID() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetSkinID() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnableTheming() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetCustomData() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetVisible() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnabled() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasAttributes() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetAttributes() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testHasAttribute() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetAttribute() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRemoveAttribute() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnableViewState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetControlState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testTrackViewState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetViewState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testClearViewState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testBindProperty() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testUnbindProperty() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testAutoBindProperty() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testDataBind() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testEnsureChildControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testCreateChildControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testFindControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testFindControlsByType() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testFindControlsByID() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testClearNamingContainer() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRegisterObject() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testUnregisterObject() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testIsObjectRegistered() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasChildInitialized() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasInitialized() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasLoadedPostData() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasLoaded() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetHasPreRendered() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetRegisteredObject() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetAllowChildControls() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testAddParsedObject() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testAddedControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRemovedControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnInit() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnLoad() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnDataBinding() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnUnload() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnPreRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testBubbleEvent() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testBroadcastEvent() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRenderControl() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRenderChildren() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSaveState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testLoadState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testApplyStyleSheetSkin() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+}
+?> \ No newline at end of file
diff --git a/tests/unit/Web/UI/TFormTest.php b/tests/unit/Web/UI/TFormTest.php
new file mode 100644
index 00000000..e2f312d6
--- /dev/null
+++ b/tests/unit/Web/UI/TFormTest.php
@@ -0,0 +1,36 @@
+<?php
+require_once dirname(__FILE__).'/../../phpunit.php';
+
+Prado::using('System.Web.UI.TForm');
+
+/**
+ * @package System.Web.UI
+ */
+class TFormTest extends PHPUnit_Framework_TestCase {
+
+ public function testOnInit() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetDefaultButton() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetMethod() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnctype() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetName() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+}
+?> \ No newline at end of file
diff --git a/tests/unit/Web/UI/TPageTest.php b/tests/unit/Web/UI/TPageTest.php
new file mode 100644
index 00000000..6f7f8268
--- /dev/null
+++ b/tests/unit/Web/UI/TPageTest.php
@@ -0,0 +1,195 @@
+<?php
+require_once dirname(__FILE__).'/../../phpunit.php';
+
+Prado::using('System.Web.UI.TPage');
+
+/**
+ * @package System.Web.UI
+ */
+class TPageTest extends PHPUnit_Framework_TestCase {
+
+ public function testConstruct() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRun() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetCallbackClient() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetCallbackEventTarget() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetCallbackEventParameter() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRegisterPostDataLoader() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetPostDataLoaders() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetForm() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetValidators() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testValidate() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetIsValid() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetTheme() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetStyleSheetTheme() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testApplyControlSkin() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testApplyControlStyleSheet() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetClientScript() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnPreInit() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnInitComplete() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnPreLoad() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnLoadComplete() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnPreRenderComplete() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testOnSaveStateComplete() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetIsPostBack() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetIsCallback() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSaveState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testLoadState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRegisterRequiresPostData() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetPostBackEventTarget() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetPostBackEventParameter() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetIsLoadingPostData() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testEnsureRenderInForm() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testBeginFormRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testEndFormRender() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetFocus() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetClientSupportsJavaScript() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetHead() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetTitle() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetClientState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetRequestClientState() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetStatePersisterClass() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetStatePersister() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnableStateValidation() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetEnableStateEncryption() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testSetAndGetPagePath() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testRegisterCachingAction() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+
+ public function testGetCachingStack() {
+ throw new PHPUnit_Framework_IncompleteTestError();
+ }
+}
+?> \ No newline at end of file