From b28efb8f88b4c3fa59273e83a7dd7585dacfd096 Mon Sep 17 00:00:00 2001 From: vissi Date: Thu, 19 Jul 2012 15:00:14 -0700 Subject: [PATCH] Allow running phpunit tests from any directory Test Plan: Run `arc unit` anywhere. Reviewers: epriestley Reviewed By: epriestley CC: aran, epriestley Differential Revision: https://secure.phabricator.com/D3017 --- src/unit/engine/PhpunitTestEngine.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/unit/engine/PhpunitTestEngine.php b/src/unit/engine/PhpunitTestEngine.php index 221e8821..baa7a201 100644 --- a/src/unit/engine/PhpunitTestEngine.php +++ b/src/unit/engine/PhpunitTestEngine.php @@ -36,11 +36,10 @@ final class PhpunitTestEngine extends ArcanistBaseUnitTestEngine { public function run() { $this->projectRoot = $this->getWorkingCopy()->getProjectRoot(); - $this->affectedTests = array(); foreach ($this->getPaths() as $path) { - $path = Filesystem::resolvePath($path); + $path = Filesystem::resolvePath($path, $this->projectRoot); // TODO: add support for directories // Users can call phpunit on the directory themselves