X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=tests%2Fbootstrap.php;h=75c01f06f4c85503e8e1f593d28f7b57fca63135;hb=e9c6611965848a5905668b8cad6fdfa4c701f609;hp=8b4b8ade1ebb473c0ff3ffe62f12fc55ee0de3c0;hpb=03038e7a3bb74bdab497d26b7f829a5c3036d1c2;p=friendica.git diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 8b4b8ade1e..75c01f06f4 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -1,5 +1,22 @@ . + * * This file is loaded by PHPUnit before any test. */ @@ -7,9 +24,15 @@ use Dice\Dice; use Friendica\DI; use PHPUnit\Framework\TestCase; +if (!file_exists(__DIR__ . '/../vendor/autoload.php')) { + die('Vendor path not found. Please execute "bin/composer.phar --no-dev install" on the command line in the web root.'); +} + +require __DIR__ . '/../vendor/autoload.php'; + // Backward compatibility if (!class_exists(TestCase::class)) { - class_alias(PHPUnit_Framework_TestCase::class, TestCase::class); + class_alias(\PHPUnit\Framework\TestCase::class, TestCase::class); } $dice = new Dice();