Skip to content

Commit

Permalink
[DoctrineExtra] command to load files
Browse files Browse the repository at this point in the history
  • Loading branch information
mpoiriert committed Jan 16, 2024
1 parent 2506bdc commit e8b7570
Show file tree
Hide file tree
Showing 9 changed files with 600 additions and 11 deletions.
4 changes: 4 additions & 0 deletions .docker/php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ RUN echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
#MONGODB
RUN pecl install mongodb 1.17.2 && docker-php-ext-enable mongodb

#MYSQL
RUN apt-get update && apt-get install -y --no-install-recommends default-mysql-client && \
rm -rf /var/lib/apt

ARG PUID=1000
ARG PGID=1000

Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,6 @@ jobs:
echo "::endgroup::"
echo "::group::Script"
php bin/console doctrine:database:create --no-interaction
php bin/console messenger:setup-transports --no-interaction
php bin/console doctrine:migrations:migrate --no-interaction --allow-no-migration -q
php bin/console doctrine:fixtures:load --no-interaction
composer test:reset
vendor/bin/phpunit --no-coverage
echo "::endgroup::"
17 changes: 13 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -245,14 +245,23 @@
"vendor/bin/phpunit"
],
"test:reset": [
"php bin/console doctrine:database:drop --if-exists --no-interaction --force",
"php bin/console doctrine:database:create --no-interaction",
"php bin/console messenger:setup-transports --no-interaction",
"php bin/console doctrine:migrations:migrate --no-interaction --allow-no-migration --quiet",
"@test:database:setup",
"php bin/console doctrine:fixtures:load --no-interaction",
"php bin/console draw:entity-migrator:setup --no-interaction",
"php bin/console draw:application:update-deployed-version --no-interaction"
],
"test:database:setup": [
"bin/console doctrine:database:drop --if-exists --no-interaction --force --env=test",
"bin/console doctrine:database:create --no-interaction --env=test",
"bin/console draw:doctrine:import-file ./data/sql/dump.sql --no-interaction --env=test",
"bin/console messenger:setup-transports --no-interaction --env=test",
"bin/console doctrine:migrations:migrate --no-interaction --allow-no-migration --quiet --env=test"
],
"test:database:setup-dump": [
"@test:database:setup",
"bin/console draw:doctrine:import-file ./data/sql/truncate.sql --no-interaction --env=test -vvv",
"bin/console draw:doctrine:mysql-dump ./data/sql/dump.sql --no-interaction --env=test"
],
"linter": [
"@linter:php-cs-fixer",
"@linter:phpstan"
Expand Down
Loading

0 comments on commit e8b7570

Please sign in to comment.