- make fixtures
- - if [[ $VALIDATE_TRANSLATION_FILE = '' ]]; then ./bin/simple-phpunit -v --debug --stop-on-failure ; fi;
+ - if [[ $VALIDATE_TRANSLATION_FILE = '' ]]; then SYMFONY_PHPUNIT_VERSION=7.0 ./bin/simple-phpunit -v --debug --stop-on-failure ; fi;
- if [[ $CS_FIXER = run ]]; then php bin/php-cs-fixer fix --verbose --dry-run ; fi;
- if [[ $VALIDATE_TRANSLATION_FILE = run ]]; then php bin/console lint:yaml src/Wallabag/CoreBundle/Resources/translations -v ; fi;
- if [[ $VALIDATE_TRANSLATION_FILE = run ]]; then php bin/console lint:yaml app/Resources/CraueConfigBundle/translations -v ; fi;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
use Symfony\Component\BrowserKit\Cookie;
use Symfony\Component\Console\Input\ArrayInput;
+use Symfony\Component\Console\Output\BufferedOutput;
use Symfony\Component\Console\Output\NullOutput;
use Wallabag\CoreBundle\Entity\Config;
use Wallabag\UserBundle\Entity\User;
$application = new Application($client->getKernel());
$application->setAutoExit(false);
- $application->run(new ArrayInput([
+ $output = new BufferedOutput();
+ $exitCode = $application->run(new ArrayInput([
'command' => 'doctrine:schema:drop',
'--no-interaction' => true,
'--force' => true,
'--env' => 'test',
- ]), new NullOutput());
+ ]), $output);
- $application->run(new ArrayInput([
+ if (0 !== $exitCode) {
+ var_dump('doctrine:schema:drop');
+ var_export($output->fetch()); die();
+ }
+
+ $output = new BufferedOutput();
+ $exitCode = $application->run(new ArrayInput([
'command' => 'doctrine:schema:create',
'--no-interaction' => true,
'--env' => 'test',
- ]), new NullOutput());
+ ]), $output);
+
+ if (0 !== $exitCode) {
+ var_dump('doctrine:schema:create');
+ var_export($output->fetch()); die();
+ }
- $application->run(new ArrayInput([
+ $output = new BufferedOutput();
+ $exitCode = $application->run(new ArrayInput([
'command' => 'doctrine:fixtures:load',
'--no-interaction' => true,
'--env' => 'test',
- ]), new NullOutput());
+ ]), $output);
+
+ if (0 !== $exitCode) {
+ var_dump('doctrine:fixtures:load');
+ var_export($output->fetch()); die();
+ }
/*
* Recreate client to avoid error: