Skip to content

Ruby3

Ruby3 #32

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
jobs:
test:
strategy:
matrix:
database: [ mysql, postgresql ]
ruby: [ 3.2, 3.1, 3.0, 2.7 ]
fail-fast: false
max-parallel: 20
runs-on: ubuntu-latest
env:
BUNDLE_JOBS: 4
BUNDLE_PATH: vendor/bundle
CI: true
DB: ${{ matrix.database }}
MYSQL_PASSWORD: root
PGHOST: localhost
PGPASSWORD: runner
PGUSER: runner
RAILS_ENV: test
RETRY_COUNT: 3
name: ${{ matrix.ruby }} ${{ matrix.database }}
steps:
- run: sudo apt-get update && sudo apt-get install libsqlite3-dev -y
- uses: actions/checkout@v2
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
ruby-version: ${{ matrix.ruby }}
- name: "Set up MySQL using VM's server"
if: ${{ env.DB == 'mysql' }}
run: |
sudo apt-get install libmysqlclient-dev -y
sudo systemctl start mysql.service
- name: "Set up PostgreSQL using VM's server"
if: ${{ env.DB == 'postgresql' }}
run: |
sudo apt-get install libpq-dev -y
sudo systemctl start postgresql.service
sudo -u postgres psql -c "CREATE USER runner WITH SUPERUSER PASSWORD 'runner'"
- run: bin/rake refinery:testing:dummy_app
- run: bin/rspec spec