Skip to content

Commit e5b7280

Browse files
committed
Fix relative path check
1 parent 13be2f3 commit e5b7280

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Context/ThenStepDefinitions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ public function then_a_specific_file_folder_should_exist( $path, $type, $strictl
456456
$path = $this->replace_variables( $path );
457457

458458
// If it's a relative path, make it relative to the current test dir.
459-
if ( DIRECTORY_SEPARATOR !== $path[0] ) {
459+
if ( DIRECTORY_SEPARATOR !== $path[0] && 0 !== strpos( $path, $this->variables['RUN_DIR'] ) ) {
460460
$path = $this->variables['RUN_DIR'] . DIRECTORY_SEPARATOR . $path;
461461
}
462462

0 commit comments

Comments
 (0)