autoload.php.dist 632 B

12345678910111213141516171819202122
  1. <?php
  2. // if the bundle is within a symfony project, try to reuse the project's autoload
  3. $autoload = __DIR__.'/../../../../../../app/autoload.php';
  4. // if the bundle is the project, try to use the composer's autoload for the tests
  5. $composerAutoload = __DIR__.'/../../vendor/autoload.php';
  6. if (is_file($autoload)) {
  7. include $autoload;
  8. } elseif (is_file($composerAutoload)) {
  9. include $composerAutoload;
  10. } else {
  11. die('Unable to find autoload.php file, please use composer to load dependencies:
  12. wget http://getcomposer.org/composer.phar
  13. php composer.phar install
  14. Visit http://getcomposer.org/ for more information.
  15. ');
  16. }