From 28c42526e4ca5730b3aada34ff3cd5243a9cbdf1 Mon Sep 17 00:00:00 2001 From: Konrad Sroga Date: Sun, 1 Sep 2024 20:40:19 +0200 Subject: [PATCH] [Tests] Tests workflow --- .github/workflows/symfony.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/symfony.yml b/.github/workflows/symfony.yml index 5fd905f..300bada 100644 --- a/.github/workflows/symfony.yml +++ b/.github/workflows/symfony.yml @@ -62,9 +62,9 @@ jobs: run: until mysqladmin ping -h127.0.0.1 -uroot -proot --silent; do sleep 1; done - name: Create Test Database - run: | - mysql -u root -proot -e "CREATE DATABASE IF NOT EXISTS test_db;" - mysql -u root -proot -e "GRANT ALL PRIVILEGES ON test_db.* TO 'test_user'@'localhost';" + run: php bin/console doctrine:database:create --if-not-exists --env=test + env: + DATABASE_URL: 'mysql://test_user:test_password@127.0.0.1:3306/test_db' - name: Run Database Migrations run: php bin/console doctrine:migrations:migrate --no-interaction --env=test