blob: c14a4dee2a11a60783fc459a6b20dad85c73d5d4 [file] [log] [blame]
Pascal Kriete69c97a72011-04-20 21:44:54 -04001<?php
2
Pascal Krietef5aee9d2011-04-21 01:20:40 -04003// Errors on full!
Pascal Kriete69c97a72011-04-20 21:44:54 -04004ini_set('display_errors', 1);
5error_reporting(E_ALL | E_STRICT);
6
Pascal Krietef5aee9d2011-04-21 01:20:40 -04007$dir = realpath(dirname(__FILE__));
Pascal Kriete69c97a72011-04-20 21:44:54 -04008
Pascal Krietef5aee9d2011-04-21 01:20:40 -04009// Path constants
10define('PROJECT_BASE', realpath($dir.'/../').'/');
Pascal Krietec5d93cb2011-04-21 00:58:51 -040011define('BASEPATH', PROJECT_BASE.'system/');
12define('APPPATH', PROJECT_BASE.'application/');
Taufan Aditya8749bc72012-03-11 05:43:45 +070013define('VIEWPATH', PROJECT_BASE.'');
Pascal Kriete69c97a72011-04-20 21:44:54 -040014
Taufan Aditya6bca9f82012-05-25 01:55:36 +070015// Get vfsStream either via pear or composer
16if (file_exists('vfsStream/vfsStream.php'))
17{
18 require_once 'vfsStream/vfsStream.php';
19}
20else
21{
22 include_once '../vendor/autoload.php';
23}
24
Pascal Krietef5aee9d2011-04-21 01:20:40 -040025// Prep our test environment
Taufan Adityaca16c4f2012-03-28 15:15:30 +070026include_once $dir.'/mocks/core/common.php';
27include_once $dir.'/mocks/autoloader.php';
28spl_autoload_register('autoload');
Pascal Krietef5aee9d2011-04-21 01:20:40 -040029
30unset($dir);