From 9a0240bc7bff9dd079b19dd26acbd6a0865fc142 Mon Sep 17 00:00:00 2001 From: jordanbrauer <18744334+jordanbrauer@users.noreply.github.com> Date: Sat, 13 Feb 2021 12:48:43 -0600 Subject: [PATCH] patch addslashes for windows paths --- src/Factories/TestCaseFactory.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Factories/TestCaseFactory.php b/src/Factories/TestCaseFactory.php index 502bb083..c09730a7 100644 --- a/src/Factories/TestCaseFactory.php +++ b/src/Factories/TestCaseFactory.php @@ -171,7 +171,7 @@ final class TestCaseFactory }, $filename); } - $filename = addslashes((string) realpath($filename)); + $filename = str_replace('\\\\', '\\', addslashes((string) realpath($filename))); $rootPath = TestSuite::getInstance()->rootPath; $relativePath = str_replace($rootPath . DIRECTORY_SEPARATOR, '', $filename); $relativePath = dirname(ucfirst($relativePath)) . DIRECTORY_SEPARATOR . basename($relativePath, '.php');