Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
JonoB committed Apr 19, 2024
1 parent c172543 commit cab1b34
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
22 changes: 9 additions & 13 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ jobs:
"kirschbaumdevelopment/laravel-test-runner:8.2",
"kirschbaumdevelopment/laravel-test-runner:8.3"
]
db_connection: [
"mysql",
"pgsql"
]

container:
image: ${{ matrix.container }}
Expand All @@ -20,19 +24,19 @@ jobs:
image: mysql:5.7
env:
MYSQL_ROOT_PASSWORD: password
MYSQL_USER: homestead
MYSQL_DATABASE: sendportal_testing
MYSQL_USER: laravel
MYSQL_PASSWORD: secret
MYSQL_DATABASE: sendportal_dev
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3

postgres:
image: postgres
env:
POSTGRES_USER: homestead
POSTGRES_DB: sendportal_testing
POSTGRES_USER: laravel
POSTGRES_PASSWORD: secret
POSTGRES_DB: sendportal_dev
ports:
- 5432:5432
options: --health-cmd="pg_isready" --health-interval=10s --health-timeout=5s --health-retries=3
Expand All @@ -44,12 +48,4 @@ jobs:
- name: Run Testsuite against MySQL
run: vendor/bin/phpunit
env:
DB_CONNECTION: mysql
DB_HOST: mysql
DB_PORT: 3306
- name: Run Testsuite against Postgres
run: vendor/bin/phpunit
env:
DB_CONNECTION: pgsql
DB_HOST: postgres
DB_PORT: 5432
DB_CONNECTION: ${{ matrix.db_connection }}
4 changes: 2 additions & 2 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
<env name="CACHE_DRIVER" value="array"/>
<env name="SESSION_DRIVER" value="array"/>
<env name="QUEUE_DRIVER" value="sync"/>
<env name="DB_DATABASE" value="sendportal-testing"/>
<env name="DB_USERNAME" value="root"/>
<env name="DB_DATABASE" value="sendportal_testing"/>
<env name="DB_USERNAME" value="laravel"/>
<env name="DB_PASSWORD" value="secret"/>
</php>
</phpunit>

0 comments on commit cab1b34

Please sign in to comment.