File tree Expand file tree Collapse file tree 2 files changed +10
-4
lines changed
src/Codeception/Lib/Connector Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change 22
22
"php" : " ^8.0" ,
23
23
"ext-json" : " *" ,
24
24
"codeception/lib-innerbrowser" : " ^3.1" ,
25
- "codeception/codeception" : " ^5.0.0-RC2"
25
+ "codeception/codeception" : " ^5.0.0-RC2" ,
26
+ "vlucas/phpdotenv" : " ^5.3"
26
27
},
27
28
"require-dev" : {
28
29
"codeception/module-asserts" : " ^3.0" ,
29
30
"codeception/module-rest" : " ^3.1" ,
30
- "laravel/framework" : " ^8.0" ,
31
- "vlucas/phpdotenv" : " ^5.3"
31
+ "laravel/framework" : " ^8.0"
32
32
},
33
33
"autoload" : {
34
34
"classmap" : [" src/" ]
Original file line number Diff line number Diff line change 9
9
use Codeception \Lib \Connector \Laravel6 \ExceptionHandlerDecorator as Laravel6ExceptionHandlerDecorator ;
10
10
use Codeception \Module \Laravel as LaravelModule ;
11
11
use Codeception \Stub ;
12
+ use Dotenv \Dotenv ;
12
13
use Exception ;
13
14
use Illuminate \Contracts \Config \Repository as Config ;
14
15
use Illuminate \Contracts \Debug \ExceptionHandler ;
@@ -186,7 +187,12 @@ private function loadApplication(): AppContract
186
187
{
187
188
/** @var AppContract $app */
188
189
$ app = require $ this ->module ->config ['bootstrap_file ' ];
189
- $ app ->loadEnvironmentFrom ($ this ->module ->config ['environment_file ' ]);
190
+ if ($ this ->module ->config ['environment_file ' ] !== '.env ' ) {
191
+ Dotenv::createMutable (
192
+ $ app ->basePath (),
193
+ $ this ->module ->config ['environment_file ' ]
194
+ )->load ();
195
+ }
190
196
$ app ->instance ('request ' , new Request ());
191
197
192
198
return $ app ;
You can’t perform that action at this time.
0 commit comments