summaryrefslogtreecommitdiff
path: root/tests/FunctionalTests/features
diff options
context:
space:
mode:
authorDavid <ottodavid@gmx.net>2015-08-10 17:58:59 +0200
committerDavid <ottodavid@gmx.net>2015-08-10 18:10:37 +0200
commitac81ab6d556ce52e98acf636bbcd8ad4d60ecf4e (patch)
tree72e4966047795a6beccc35f3e323ed10fbdd8c80 /tests/FunctionalTests/features
parent2bf1a517f3edc1bd43b8e3340f0f6fd31b1ba94a (diff)
First support for pages with namespaced page class files
Diffstat (limited to 'tests/FunctionalTests/features')
-rw-r--r--tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.page3
-rw-r--r--tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.php14
-rw-r--r--tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.page3
-rw-r--r--tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.php6
-rw-r--r--tests/FunctionalTests/features/tests/NamespacesTestCase.php17
5 files changed, 43 insertions, 0 deletions
diff --git a/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.page b/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.page
new file mode 100644
index 00000000..842868ba
--- /dev/null
+++ b/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.page
@@ -0,0 +1,3 @@
+<com:TContent ID="Content">
+ With Namespaces loaded
+</com:TContent> \ No newline at end of file
diff --git a/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.php b/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.php
new file mode 100644
index 00000000..5a49f6f6
--- /dev/null
+++ b/tests/FunctionalTests/features/protected/pages/Namespaces/WithNamespace.php
@@ -0,0 +1,14 @@
+<?php
+
+namespace Application\Pages\Namespaces;
+
+use Prado\Web\UI\TPage;
+
+class WithNamespace extends TPage
+{
+
+ public function __construct()
+ {
+ parent::__construct();
+ }
+} \ No newline at end of file
diff --git a/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.page b/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.page
new file mode 100644
index 00000000..28d38cec
--- /dev/null
+++ b/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.page
@@ -0,0 +1,3 @@
+<com:TContent ID="Content">
+ Without Namespaces loaded
+</com:TContent> \ No newline at end of file
diff --git a/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.php b/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.php
new file mode 100644
index 00000000..ad671e7f
--- /dev/null
+++ b/tests/FunctionalTests/features/protected/pages/Namespaces/WithoutNamespace.php
@@ -0,0 +1,6 @@
+<?php
+
+class WithoutNamespace extends TPage
+{
+
+} \ No newline at end of file
diff --git a/tests/FunctionalTests/features/tests/NamespacesTestCase.php b/tests/FunctionalTests/features/tests/NamespacesTestCase.php
new file mode 100644
index 00000000..f712d526
--- /dev/null
+++ b/tests/FunctionalTests/features/tests/NamespacesTestCase.php
@@ -0,0 +1,17 @@
+<?php
+
+
+class NamespacesTestCase extends \PradoGenericSelenium2Test
+{
+ public function test()
+ {
+ $this->url("features/index.php?page=Namespaces.WithoutNamespace");
+ $this->pause(50);
+ $this->assertContains('Without Namespaces loaded', $this->source());
+
+ $this->url("features/index.php?page=Namespaces.WithNamespace");
+ $this->pause(50);
+ $this->assertContains('With Namespaces loaded', $this->source());
+ }
+
+} \ No newline at end of file