Skip to content

Commit

Permalink
DB multi-versions tests (#94)
Browse files Browse the repository at this point in the history
* chore: adding env vars

* test

* hmm

* chore: try the new syntax

* chore: new syntax fix
  • Loading branch information
JasonShin authored Jan 13, 2024
1 parent 83fc8f1 commit a5a0ed7
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/rust-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,17 @@ env:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
db:
- mysql: 8
- mysql: 5.7
- mysql: 5.6
- postgres: 16
- postgres: 15
- postgres: 14
- postgres: 13
- postgres: 12

steps:
- name: Checkout sources
Expand All @@ -37,6 +48,9 @@ jobs:

- name: build docker-compose services for integration tests
run: docker-compose -f docker-compose.yml up -d
env:
MYSQL_VERSION: ${{ matrix.db.mysql }}
PG_VERSION: ${{ matrix.db.postgres }}

- uses: GuillaumeFalourd/wait-sleep-action@v1
with:
Expand Down
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: '3.1'
services:

postgres:
image: postgres:13
image: postgres:${PG_VERSION:-13}
restart: always
environment:
POSTGRES_PASSWORD: postgres
Expand All @@ -13,7 +13,7 @@ services:
- 54321:5432

mysql:
image: mysql:8
image: mysql:${MYSQL_VERSION:-8}
restart: always
volumes:
- ./playpen/db/mysql_migration.sql:/docker-entrypoint-initdb.d/mysql_migration.sql
Expand Down

0 comments on commit a5a0ed7

Please sign in to comment.