Skip to content
Extraits de code Groupes Projets
Valider 63f9f68b rédigé par mattab's avatar mattab
Parcourir les fichiers

Merge remote-tracking branch 'origin/master'

parents 10521d55 8abd0210
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -55,6 +55,9 @@ class SetupFixture extends ConsoleCommand ...@@ -55,6 +55,9 @@ class SetupFixture extends ConsoleCommand
throw new \Exception("Required argument --db-name is not set."); throw new \Exception("Required argument --db-name is not set.");
} }
$this->requireFixtureFiles();
$this->setIncludePathAsInTestBootstrap();
$file = $input->getOption('file'); $file = $input->getOption('file');
if ($file) { if ($file) {
if (is_file($file)) { if (is_file($file)) {
...@@ -70,9 +73,6 @@ class SetupFixture extends ConsoleCommand ...@@ -70,9 +73,6 @@ class SetupFixture extends ConsoleCommand
Url::setHost('localhost'); Url::setHost('localhost');
} }
$this->requireFixtureFiles();
$this->setIncludePathAsInTestBootstrap();
// get the fixture class // get the fixture class
$fixtureClass = $input->getArgument('fixture'); $fixtureClass = $input->getArgument('fixture');
if (class_exists("Piwik\\Tests\\Fixtures\\" . $fixtureClass)) { if (class_exists("Piwik\\Tests\\Fixtures\\" . $fixtureClass)) {
...@@ -86,6 +86,7 @@ class SetupFixture extends ConsoleCommand ...@@ -86,6 +86,7 @@ class SetupFixture extends ConsoleCommand
// create the fixture // create the fixture
$fixture = new $fixtureClass(); $fixture = new $fixtureClass();
$fixture->dbName = $dbName; $fixture->dbName = $dbName;
$fixture->printToScreen = true;
Config::getInstance()->setTestEnvironment(); Config::getInstance()->setTestEnvironment();
$fixture->createConfig = false; $fixture->createConfig = false;
......
...@@ -19,10 +19,6 @@ ...@@ -19,10 +19,6 @@
-- Current Database: `piwik_tests` -- Current Database: `piwik_tests`
-- --
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `piwik_tests` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `piwik_tests`;
-- --
-- Table structure for table `piwiktests_access` -- Table structure for table `piwiktests_access`
-- --
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter