Merge pull request #21 from michalochman/allow-relative-files-path
Allow relative paths in files_path
This commit is contained in:
@@ -178,7 +178,7 @@ class MinkContext extends RawMinkContext implements TranslatedContextInterface
|
|||||||
$field = $this->fixStepArgument($field);
|
$field = $this->fixStepArgument($field);
|
||||||
|
|
||||||
if ($this->getMinkParameter('files_path')) {
|
if ($this->getMinkParameter('files_path')) {
|
||||||
$fullPath = rtrim($this->getMinkParameter('files_path'), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.$path;
|
$fullPath = rtrim(realpath($this->getMinkParameter('files_path')), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.$path;
|
||||||
if (is_file($fullPath)) {
|
if (is_file($fullPath)) {
|
||||||
$path = $fullPath;
|
$path = $fullPath;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user