summaryrefslogtreecommitdiffstats
path: root/debian/perl-framework/t/htdocs/modules/include/apexpr
diff options
context:
space:
mode:
Diffstat (limited to 'debian/perl-framework/t/htdocs/modules/include/apexpr')
-rw-r--r--debian/perl-framework/t/htdocs/modules/include/apexpr/err.shtml3
-rw-r--r--debian/perl-framework/t/htdocs/modules/include/apexpr/if1.shtml6
-rw-r--r--debian/perl-framework/t/htdocs/modules/include/apexpr/lazyvar.shtml5
-rw-r--r--debian/perl-framework/t/htdocs/modules/include/apexpr/restrict.shtml3
-rw-r--r--debian/perl-framework/t/htdocs/modules/include/apexpr/var.shtml16
5 files changed, 33 insertions, 0 deletions
diff --git a/debian/perl-framework/t/htdocs/modules/include/apexpr/err.shtml b/debian/perl-framework/t/htdocs/modules/include/apexpr/err.shtml
new file mode 100644
index 0000000..2afda99
--- /dev/null
+++ b/debian/perl-framework/t/htdocs/modules/include/apexpr/err.shtml
@@ -0,0 +1,3 @@
+<!--#if expr="1 = 2 = 3" -->
+<!--#include virtual="../echo.shtml" -->
+<!--#endif -->
diff --git a/debian/perl-framework/t/htdocs/modules/include/apexpr/if1.shtml b/debian/perl-framework/t/htdocs/modules/include/apexpr/if1.shtml
new file mode 100644
index 0000000..ec9c855
--- /dev/null
+++ b/debian/perl-framework/t/htdocs/modules/include/apexpr/if1.shtml
@@ -0,0 +1,6 @@
+<!--#if expr="'ab' -strmatch 'a*'"-->
+pass
+<!--#endif -->
+<!--#if expr="'ab' -strmatch 'b*'"-->
+fail
+<!--#endif -->
diff --git a/debian/perl-framework/t/htdocs/modules/include/apexpr/lazyvar.shtml b/debian/perl-framework/t/htdocs/modules/include/apexpr/lazyvar.shtml
new file mode 100644
index 0000000..743ebf7
--- /dev/null
+++ b/debian/perl-framework/t/htdocs/modules/include/apexpr/lazyvar.shtml
@@ -0,0 +1,5 @@
+<!--#if expr="v('DATE_LOCAL') =~ /[0-9]/" -->
+pass
+<!--#else-->
+fail
+<!--#endif-->
diff --git a/debian/perl-framework/t/htdocs/modules/include/apexpr/restrict.shtml b/debian/perl-framework/t/htdocs/modules/include/apexpr/restrict.shtml
new file mode 100644
index 0000000..5c095f8
--- /dev/null
+++ b/debian/perl-framework/t/htdocs/modules/include/apexpr/restrict.shtml
@@ -0,0 +1,3 @@
+<!--#if expr="-e '/etc/passwd'" -->
+<!--#include virtual="../echo.shtml" -->
+<!--#endif -->
diff --git a/debian/perl-framework/t/htdocs/modules/include/apexpr/var.shtml b/debian/perl-framework/t/htdocs/modules/include/apexpr/var.shtml
new file mode 100644
index 0000000..9521c90
--- /dev/null
+++ b/debian/perl-framework/t/htdocs/modules/include/apexpr/var.shtml
@@ -0,0 +1,16 @@
+<!--#set var="x" value="foo bar"-->
+<!--#if expr="reqenv('x') =~ /^foo/ && reqenv('x') =~ /bar$/" -->
+pass
+<!--#else-->
+fail
+<!--#endif-->
+<!--#if expr="env('x') =~ /^foo/ && v('x') =~ /bar$/" -->
+pass
+<!--#else-->
+fail
+<!--#endif-->
+<!--#if expr="note('x') =~ /^foo/" -->
+fail
+<!--#else-->
+pass
+<!--#endif-->