Permalink
Browse files

Merge pull request #87 from Adel-E/fix-phpunit-config

Fix phpunit config to use the composer autoload and remove typos
  • Loading branch information...
2 parents 9c0ec36 + a55de03 commit dce244cc8ea3ada880e684f8d55c77cce01f19c7 @beberlei committed Jun 30, 2013
Showing with 16 additions and 44 deletions.
  1. +0 −27 tests/DoctrineExtensions/TestHelper.php
  2. +16 −17 tests/phpunit.dist.xml
@@ -1,27 +0,0 @@
-<?php
-
-use
- Doctrine\Common\ClassLoader,
- Doctrine\Common\Cache,
- Doctrine\ORM\Configuration,
- Doctrine\ORM\EntityManager
-;
-
-if (!isset($GLOBALS['doctrine2-path'])) {
- throw new InvalidArgumentException('Global variable "doctrine2-path" has to be set in phpunit.xml');
-}
-
-$loaderfile = $GLOBALS['doctrine2-path']."/Doctrine/Common/ClassLoader.php";
-if (!file_exists($loaderfile)) {
- throw new InvalidArgumentException('Could not include Doctrine\Common\ClassLoader from "doctrine2-path".');
-}
-require_once($loaderfile);
-
-$loader = new Doctrine\Common\ClassLoader("Doctrine", $GLOBALS['doctrine2-path']);
-$loader->register();
-
-$loader = new Doctrine\Common\ClassLoader("DoctrineExtensions", __DIR__."/../../lib");
-$loader->register();
-
-$loader = new Doctrine\Common\ClassLoader("Entities", realpath(__DIR__."/.."));
-$loader->register();
View
@@ -1,25 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
-<<<<<<< .merge_file_0MDGRJ
<phpunit
- bootstrap="./DoctrineExtensions/TestHelper.php"
- colors="true"
+ bootstrap="../vendor/autoload.php"
+ colors="true"
>
- <testsuites>
- <testsuite name="AllTests">
- <directory>DoctrineExtensions/LargeCollections</directory>
- <directory>DoctrineExtensions/Paginate</directory>
- <directory>DoctrineExtensions/Query</directory>
- </testsuite>
- </testsuites>
- <php>
+ <testsuites>
+ <testsuite name="AllTests">
+ <directory>DoctrineExtensions/LargeCollections</directory>
+ <directory>DoctrineExtensions/Paginate</directory>
+ <directory>DoctrineExtensions/Query</directory>
+ </testsuite>
+ </testsuites>
+ <php>
<var name="doctrine2-path" value="" />
<var name="doctrine2-entities-path" value="" />
<var name="doctrine2-proxies-path" value="" />
<var name="doctrine2-proxies-namespace" value="" />
- </php>
- <filter>
- <blacklist>
- <directory suffix=".php"></directory>
- </blacklist>
- </filter>
+ </php>
+ <filter>
+ <blacklist>
+ <directory suffix=".php"></directory>
+ </blacklist>
+ </filter>
</phpunit>

0 comments on commit dce244c

Please sign in to comment.