Skip to content

Commit

Permalink
#143 : make nelmio/alice optinal
Browse files Browse the repository at this point in the history
  • Loading branch information
Nicolas Bastien committed Mar 21, 2015
1 parent 800a243 commit c1ada37
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 8 additions & 2 deletions Test/WebTestCase.php
Expand Up @@ -364,12 +364,18 @@ protected function loadFixtures(array $classNames, $omName = null, $registryName

/**
* @param array $paths
* @param bool $append
* @param bool $append
* @param null $omName
* @param string $registryName
*
* @return $this
* @throws \BadMethodCallException
*/
public function loadFixtureFiles(array $paths = [], $append = false, $omName = null, $registryName = 'doctrine')
{
if (!class_exists('Nelmio\Alice\Fixtures')) {
throw new \BadMethodCallException('nelmio/alice should be installed to use this method.');
}

$om = $this->getObjectManager($omName, $registryName);

if ($append == false) {
Expand Down
6 changes: 3 additions & 3 deletions composer.json
Expand Up @@ -18,13 +18,13 @@
"php": ">=5.3.2",
"symfony/framework-bundle": "~2.0",
"symfony/browser-kit": "~2.0",
"doctrine/common": "2.*",
"nelmio/alice": "~1.7"
"doctrine/common": "2.*"
},
"suggest": {
"doctrine/doctrine-fixtures-bundle": "Required when using the fixture loading functionality",
"doctrine/orm": "Required when using the fixture loading functionality with an ORM and SQLite",
"doctrine/dbal": "Required when using the fixture loading functionality with an ORM and SQLite"
"doctrine/dbal": "Required when using the fixture loading functionality with an ORM and SQLite",
"nelmio/alice": "Required when using loadFixtureFiles functionality"
},
"autoload": {
"psr-4": {
Expand Down

0 comments on commit c1ada37

Please sign in to comment.