From b6f3f93ff821da84266e223aba4715e454c91f9b Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 21 Feb 2013 01:22:52 +0000 Subject: [PATCH] + add tests about getwebroot method. --- .../tests/helper/.201.getwebroot.inbrowse.et | 2 + .../tests/helper/.202.getwebroot.inshell.et | 8 ++++ .../tests/helper/201.getwebroot.inbrowse.php | 17 ++++++++ .../tests/helper/202.getwebroot.inshell.php | 43 +++++++++++++++++++ 4 files changed, 70 insertions(+) create mode 100644 framework/tests/helper/.201.getwebroot.inbrowse.et create mode 100644 framework/tests/helper/.202.getwebroot.inshell.et create mode 100755 framework/tests/helper/201.getwebroot.inbrowse.php create mode 100755 framework/tests/helper/202.getwebroot.inshell.php diff --git a/framework/tests/helper/.201.getwebroot.inbrowse.et b/framework/tests/helper/.201.getwebroot.inbrowse.et new file mode 100644 index 0000000000..618380792d --- /dev/null +++ b/framework/tests/helper/.201.getwebroot.inbrowse.et @@ -0,0 +1,2 @@ +/ +/zentao/ diff --git a/framework/tests/helper/.202.getwebroot.inshell.et b/framework/tests/helper/.202.getwebroot.inshell.et new file mode 100644 index 0000000000..3de39a7763 --- /dev/null +++ b/framework/tests/helper/.202.getwebroot.inshell.et @@ -0,0 +1,8 @@ +http://localhost webRoot is / +http://localhost/ webRoot is / +http://localhost/my/ webRoot is / +http://localhost/my-todo.html webRoot is / +http://localhost/index.php?m=my&f=index webRoot is / +http://localhost/zentao/my/ webRoot is /zentao/ +http://localhost/zentao/my-todo.html webRoot is /zentao/ +http://localhost/zentao/index.php?m=my&f=index webRoot is /zentao/ diff --git a/framework/tests/helper/201.getwebroot.inbrowse.php b/framework/tests/helper/201.getwebroot.inbrowse.php new file mode 100755 index 0000000000..a630da9b4d --- /dev/null +++ b/framework/tests/helper/201.getwebroot.inbrowse.php @@ -0,0 +1,17 @@ +#!/usr/bin/env php +