2011-02-28 22:30:22 -06:00
|
|
|
<?php
|
|
|
|
|
|
|
|
error_reporting(E_ALL | E_STRICT);
|
|
|
|
|
2012-01-14 13:57:05 -06:00
|
|
|
// Ensure that composer has installed all dependencies
|
2012-06-04 12:17:20 -07:00
|
|
|
if (!file_exists(dirname(__DIR__) . '/composer.lock')) {
|
2012-04-16 15:13:53 -07:00
|
|
|
die("Dependencies must be installed using composer:\n\nphp composer.phar install --dev\n\n"
|
|
|
|
. "See http://getcomposer.org for help with installing composer\n");
|
2012-01-14 13:57:05 -06:00
|
|
|
}
|
|
|
|
|
2011-02-28 22:30:22 -06:00
|
|
|
require_once 'PHPUnit/TextUI/TestRunner.php';
|
|
|
|
|
2012-06-14 09:49:05 -07:00
|
|
|
// Include the phar files if testing against the phars
|
2012-04-14 18:43:34 -07:00
|
|
|
if (get_cfg_var('guzzle_phar')) {
|
|
|
|
require get_cfg_var('guzzle_phar');
|
|
|
|
}
|
|
|
|
|
2012-01-14 13:57:05 -06:00
|
|
|
// Include the composer autoloader
|
2012-10-31 21:27:06 -07:00
|
|
|
$autoloader = require dirname(__DIR__) . '/vendor/autoload.php';
|
2011-02-28 22:30:22 -06:00
|
|
|
|
2012-01-14 13:57:05 -06:00
|
|
|
// Add the services file to the default service builder
|
2012-09-12 12:16:51 -07:00
|
|
|
$servicesFile = __DIR__ . '/Guzzle/Tests/TestData/services/services.json';
|
2012-05-13 17:20:26 -07:00
|
|
|
Guzzle\Tests\GuzzleTestCase::setServiceBuilder(Guzzle\Service\Builder\ServiceBuilder::factory($servicesFile));
|