File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change 53
53
* modules:
54
54
* enabled:
55
55
* - Yii2:
56
- * configFile: '/ path/to/config.php'
56
+ * configFile: 'path/to/config.php'
57
57
* ```
58
58
*
59
59
* ### Parts
@@ -238,10 +238,12 @@ private function initServerGlobal()
238
238
protected function validateConfig ()
239
239
{
240
240
parent ::validateConfig ();
241
- if (!is_file (Configuration::projectDir () . $ this ->config ['configFile ' ])) {
241
+
242
+ $ pathToConfig = codecept_absolute_path ($ this ->config ['configFile ' ]);
243
+ if (!is_file ($ pathToConfig )) {
242
244
throw new ModuleConfigException (
243
245
__CLASS__ ,
244
- "The application config file does not exist: " . Configuration:: projectDir () . $ this -> config [ ' configFile ' ]
246
+ "The application config file does not exist: " . $ pathToConfig
245
247
);
246
248
}
247
249
@@ -262,7 +264,7 @@ protected function validateConfig()
262
264
263
265
protected function configureClient (array $ settings )
264
266
{
265
- $ settings ['configFile ' ] = Configuration:: projectDir () . $ settings ['configFile ' ];
267
+ $ settings ['configFile ' ] = codecept_absolute_path ( $ settings ['configFile ' ]) ;
266
268
267
269
foreach ($ settings as $ key => $ value ) {
268
270
if (property_exists ($ this ->client , $ key )) {
You can’t perform that action at this time.
0 commit comments