From 06d6b715a3be119a2bb688a44a95eaa25f8b9cd2 Mon Sep 17 00:00:00 2001 From: Roman Syroeshko Date: Tue, 14 Oct 2014 21:06:47 +0400 Subject: [PATCH] [CHANGED] "tests/bootstrap.php". --- tests/bootstrap.php | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/tests/bootstrap.php b/tests/bootstrap.php index d0dcdba7..4932a21b 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -23,16 +23,10 @@ if (!defined('PHPWORD_TESTS_BASE_DIR')) { } $vendor = realpath(__DIR__ . '/../vendor'); - -if (file_exists($vendor . "/autoload.php")) { - require $vendor . "/autoload.php"; +if (file_exists($vendor . '/autoload.php')) { + require $vendor . '/autoload.php'; } else { - $vendor = realpath(__DIR__ . '/../../../'); - if (file_exists($vendor . "/autoload.php")) { - require $vendor . "/autoload.php"; - } else { - throw new Exception("Unable to load dependencies"); - } + throw new Exception('Unable to load dependencies'); } spl_autoload_register(function ($class) { @@ -49,5 +43,5 @@ spl_autoload_register(function ($class) { } }); -require_once __DIR__ . "/../src/PhpWord/Autoloader.php"; +require_once __DIR__ . '/../src/PhpWord/Autoloader.php'; \PhpOffice\PhpWord\Autoloader::register();