|
@@ -17,12 +17,12 @@ $lastDir = null;
|
|
while ($dir !== $lastDir) {
|
|
while ($dir !== $lastDir) {
|
|
$lastDir = $dir;
|
|
$lastDir = $dir;
|
|
|
|
|
|
- if (is_file($dir.'/autoload.php')) {
|
|
|
|
|
|
+ if (file_exists($dir.'/autoload.php')) {
|
|
require_once $dir.'/autoload.php';
|
|
require_once $dir.'/autoload.php';
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
|
|
|
|
- if (is_file($dir.'/autoload.php.dist')) {
|
|
|
|
|
|
+ if (file_exists($dir.'/autoload.php.dist')) {
|
|
require_once $dir.'/autoload.php.dist';
|
|
require_once $dir.'/autoload.php.dist';
|
|
break;
|
|
break;
|
|
}
|
|
}
|
|
@@ -52,7 +52,7 @@ class AppKernel extends Kernel
|
|
$this->testCase = $testCase;
|
|
$this->testCase = $testCase;
|
|
|
|
|
|
$fs = new Filesystem();
|
|
$fs = new Filesystem();
|
|
- if (!$fs->isAbsolutePath($rootConfig) && !is_file($rootConfig = __DIR__.'/'.$testCase.'/'.$rootConfig)) {
|
|
|
|
|
|
+ if (!$fs->isAbsolutePath($rootConfig) && !file_exists($rootConfig = __DIR__.'/'.$testCase.'/'.$rootConfig)) {
|
|
throw new \InvalidArgumentException(sprintf('The root config "%s" does not exist.', $rootConfig));
|
|
throw new \InvalidArgumentException(sprintf('The root config "%s" does not exist.', $rootConfig));
|
|
}
|
|
}
|
|
$this->rootConfig = $rootConfig;
|
|
$this->rootConfig = $rootConfig;
|
|
@@ -62,7 +62,7 @@ class AppKernel extends Kernel
|
|
|
|
|
|
public function registerBundles()
|
|
public function registerBundles()
|
|
{
|
|
{
|
|
- if (!is_file($filename = $this->getRootDir().'/'.$this->testCase.'/bundles.php')) {
|
|
|
|
|
|
+ if (!file_exists($filename = $this->getRootDir().'/'.$this->testCase.'/bundles.php')) {
|
|
throw new \RuntimeException(sprintf('The bundles file "%s" does not exist.', $filename));
|
|
throw new \RuntimeException(sprintf('The bundles file "%s" does not exist.', $filename));
|
|
}
|
|
}
|
|
|
|
|