Skip to content

Commit

Permalink
Fix testing bootstrap
Browse files Browse the repository at this point in the history
  • Loading branch information
davidwdan committed Mar 21, 2017
1 parent f65397d commit 5713dcd
Showing 1 changed file with 4 additions and 19 deletions.
23 changes: 4 additions & 19 deletions tests/bootstrap.php
Original file line number Diff line number Diff line change
@@ -1,24 +1,9 @@
<?php
/**
* Find the auto loader file
*/
$locations = [
__DIR__ . '/../',
__DIR__ . '/../../',
__DIR__ . '/../../../',
__DIR__ . '/../../../../',
];


foreach ($locations as $location) {

$file = $location . "vendor/autoload.php";

if (file_exists($file)) {
$loader = require_once $file;
$loader->addPsr4('Rx\\Thruway\\Tests\\', __DIR__);
break;
}
if (file_exists($file = __DIR__ . '/../vendor/autoload.php')) {
require $file;
} else {
throw new RuntimeException('Install dependencies to run test suite.');
}

/**
Expand Down

0 comments on commit 5713dcd

Please sign in to comment.