summaryrefslogtreecommitdiffstats
path: root/tests/mocks/core/uri.php
diff options
context:
space:
mode:
authordchill42 <dchill42@gmail.com>2012-07-23 16:53:47 +0200
committerdchill42 <dchill42@gmail.com>2012-07-23 16:53:47 +0200
commitc5079de78e5141330c07e990811ef15e998e95aa (patch)
tree0f39d8c4fc7614246fc185810bfeaa7fad88a33a /tests/mocks/core/uri.php
parent00fcb545109d4e61bc14e403ec828749c34a54b3 (diff)
parentede49ba66b127535f3430e20aac72ceed2c4611a (diff)
Merge branch develop of github.com:/EllisLab/CodeIgniter into session
Diffstat (limited to 'tests/mocks/core/uri.php')
-rw-r--r--tests/mocks/core/uri.php26
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/mocks/core/uri.php b/tests/mocks/core/uri.php
new file mode 100644
index 000000000..94f75df64
--- /dev/null
+++ b/tests/mocks/core/uri.php
@@ -0,0 +1,26 @@
+<?php
+
+class Mock_Core_URI extends CI_URI {
+
+ public function __construct()
+ {
+ $test = CI_TestCase::instance();
+ $cls =& $test->ci_core_class('cfg');
+
+ // set predictable config values
+ $test->ci_set_config(array(
+ 'index_page' => 'index.php',
+ 'base_url' => 'http://example.com/',
+ 'subclass_prefix' => 'MY_'
+ ));
+
+ $this->config = new $cls;
+
+ }
+
+ protected function _is_cli_request()
+ {
+ return FALSE;
+ }
+
+} \ No newline at end of file