Total Complexity | 5 |
Total Lines | 54 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
9 | class DemoTest extends TestCase |
||
10 | { |
||
11 | /** |
||
12 | * @var string |
||
13 | */ |
||
14 | private $PACKAGE_NAME = "LaravelQueryHelper"; |
||
15 | |||
16 | /** |
||
17 | * @var array |
||
18 | */ |
||
19 | private $PACKAGE_CLASSES = [ |
||
20 | "QueryHelper", |
||
21 | ]; |
||
22 | |||
23 | /** |
||
24 | * @var string |
||
25 | */ |
||
26 | private $VENDOR = 'Alive2212'; |
||
27 | |||
28 | protected $app; |
||
29 | |||
30 | public function __construct() |
||
34 | } |
||
35 | |||
36 | public function createApplication() |
||
37 | { |
||
38 | $app = new Container(); |
||
39 | $app->bind('app', 'Illuminate\Container\Container'); |
||
40 | |||
41 | foreach ($this->PACKAGE_CLASSES as $PACKAGE_CLASS) { |
||
42 | $app->bind($PACKAGE_CLASS, $this->VENDOR.'\\'.$this->PACKAGE_NAME.'\\'.$PACKAGE_CLASS); |
||
43 | } |
||
44 | |||
45 | $app->bind('Cache', 'Illuminate\Support\Facades\Cache'); |
||
46 | |||
47 | $this->app = $app; |
||
48 | Facade::setFacadeApplication($app); |
||
|
|||
49 | } |
||
50 | |||
51 | /** |
||
52 | * A basic test example. |
||
53 | * |
||
54 | * @return void |
||
55 | */ |
||
56 | public function testBasicTest() |
||
63 | } |
||
64 | } |
||
65 |