1 | <?php |
||
9 | class TestHelperCntl |
||
10 | { |
||
11 | private static $aimeos; |
||
12 | private static $context; |
||
13 | |||
14 | |||
15 | public static function bootstrap() |
||
16 | { |
||
17 | self::getAimeos(); |
||
18 | \Aimeos\MShop::cache( false ); |
||
19 | } |
||
20 | |||
21 | |||
22 | public static function getContext( $site = 'unittest' ) |
||
29 | } |
||
30 | |||
31 | |||
32 | public static function getAimeos() |
||
33 | { |
||
34 | if( !isset( self::$aimeos ) ) |
||
35 | { |
||
36 | require_once 'Bootstrap.php'; |
||
37 | spl_autoload_register( 'Aimeos\\Bootstrap::autoload' ); |
||
38 | |||
39 | $extdir = dirname( dirname( dirname( dirname( dirname( __FILE__ ) ) ) ) ); |
||
40 | self::$aimeos = new \Aimeos\Bootstrap( array( $extdir ), true ); |
||
41 | } |
||
42 | |||
43 | return self::$aimeos; |
||
44 | } |
||
45 | |||
46 | |||
47 | /** |
||
48 | * @param string $site |
||
49 | */ |
||
50 | private static function createContext( $site ) |
||
86 | } |
||
87 | } |
||
88 |