Permalink
Browse files

updated test suite to use composer loader

closes #81
  • Loading branch information...
1 parent 5c7d052 commit d572ab53fece8287592d8599e8439d5771f10649 @kriswallsmith committed Jun 25, 2012
Showing with 16 additions and 10 deletions.
  1. +3 −0 .gitignore
  2. +13 −10 test/bootstrap.php
View
@@ -1 +1,4 @@
+composer.lock
+composer.phar
phpunit.xml
+vendor
View
@@ -1,12 +1,15 @@
<?php
-spl_autoload_register(function($class)
-{
- if (0 === strpos($class, 'Buzz\\')) {
- $file = __DIR__ . '/../lib/' . str_replace('\\', '/', $class) . '.php';
- if (file_exists($file)) {
- require_once $file;
- return true;
- }
- }
-});
+if (!$loader = @include __DIR__.'/../vendor/autoload.php') {
+ echo <<<EOM
+You must set up the project dependencies by running the following commands:
+
+ curl -s http://getcomposer.org/installer | php
+ php composer.phar install
+
+EOM;
+
+ exit(1);
+}
+
+$loader->add('Buzz\Test', __DIR__);

0 comments on commit d572ab5

Please sign in to comment.