diff options
author | Frederic Guillot <fred@kanboard.net> | 2016-05-02 20:34:51 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2016-05-02 20:34:51 -0400 |
commit | 38e9f9928e3f13658af3c6bbe9ec0bf078f1c177 (patch) | |
tree | 56132dcb7de9dc75d176b765d81e8c06b2e86fd2 /tests/units | |
parent | e58352b18f49e3ca23dd0681a039c38e718c9c13 (diff) |
Added auto-loading in tests for plugins
Diffstat (limited to 'tests/units')
-rw-r--r-- | tests/units/Base.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/units/Base.php b/tests/units/Base.php index 5125ffb9..6825a6bf 100644 --- a/tests/units/Base.php +++ b/tests/units/Base.php @@ -3,6 +3,7 @@ require __DIR__.'/../../vendor/autoload.php'; require __DIR__.'/../../app/constants.php'; +use Composer\Autoload\ClassLoader; use Symfony\Component\EventDispatcher\EventDispatcher; use Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher; use Symfony\Component\Stopwatch\Stopwatch; @@ -82,6 +83,10 @@ abstract class Base extends PHPUnit_Framework_TestCase $this->container['flash'] = function ($c) { return new FlashMessage($c); }; + + $loader = new ClassLoader(); + $loader->addPsr4('Kanboard\Plugin\\', PLUGINS_DIR); + $loader->register(); } public function tearDown() |