Added scripts to run phpunit tests
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
* with this source code in the file LICENSE.
|
||||
*/
|
||||
|
||||
namespace Bundle\WebServiceBundle\Tests;
|
||||
namespace Bundle\WebServiceBundle\Tests\Soap;
|
||||
|
||||
use Bundle\WebServiceBundle\Soap\SoapRequest;
|
||||
|
25
Tests/bootstrap.php
Normal file
25
Tests/bootstrap.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
require_once $_SERVER['SYMFONY'].'/Symfony/Component/ClassLoader/UniversalClassLoader.php';
|
||||
|
||||
use Symfony\Component\ClassLoader\UniversalClassLoader;
|
||||
|
||||
$loader = new UniversalClassLoader();
|
||||
$loader->registerNamespace('Symfony', $_SERVER['SYMFONY']);
|
||||
$loader->registerNamespace('Zend', $_SERVER['ZEND']);
|
||||
$loader->register();
|
||||
|
||||
spl_autoload_register(function($class) {
|
||||
//if (0 === strpos($class, 'BeSimple\\SoapBundle\\')) {
|
||||
if (0 === strpos($class, 'Bundle\\WebServiceBundle\\')) {
|
||||
$path = __DIR__.'/../'.implode('/', array_slice(explode('\\', $class), 2)).'.php';
|
||||
|
||||
if (file_exists($path)) {
|
||||
require_once $path;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
});
|
Reference in New Issue
Block a user