Skip to content

Commit

Permalink
chore: update test workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
bethesque committed Nov 25, 2020
1 parent a1aeff9 commit 8b2a8cf
Showing 1 changed file with 36 additions and 11 deletions.
47 changes: 36 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,44 @@ name: Test
on: push

jobs:
test:
# test:
# runs-on: ubuntu-latest
# strategy:
# matrix:
# database_adapter: ["mysql", "postgres", "sqlite"]
# ruby_version: [2.5, 2.7]
# env:
# INSTALL_PG: ${{ matrix.database_adapter == 'postgres' }}
# INSTALL_MYSQL: ${{ matrix.database_adapter == 'mysql' }}
# steps:
# - uses: actions/checkout@v2
# - uses: actions/setup-ruby@v1
# with:
# ruby-version: ${{ matrix.ruby_version }}
# - run: "bundle install"
# - run: "bundle exec rake"
postgres:
runs-on: ubuntu-latest
strategy:
matrix:
database_adapter: ["mysql", "postgres", "sqlite"]
ruby_version: [2.5, 2.7]
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
env:
INSTALL_PG: ${{ matrix.database_adapter == 'postgres' }}
INSTALL_MYSQL: ${{ matrix.database_adapter == 'mysql' }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby_version }}
- run: "bundle install"
- run: "bundle exec rake"
INSTALL_PG: true
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby_version }}
- run: "bundle install"
- run: "bundle exec rake"

0 comments on commit 8b2a8cf

Please sign in to comment.