Skip to content

Support for ruby 3.2. Drop older ruby versions and que #91

Support for ruby 3.2. Drop older ruby versions and que

Support for ruby 3.2. Drop older ruby versions and que #91

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
name: Main CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
ruby: ['3.2.2']
gemfile:
- gemfiles/ruby_kafka.gemfile
- gemfiles/rails_7.0.gemfile
- gemfiles/shoryuken_6.0.gemfile
- gemfiles/sidekiq_5.0.gemfile
- gemfiles/sinatra_2.2.gemfile
allow_failures:
- false
include:
- os: ubuntu
ruby-version: ruby-head
gemfile: gemfiles/rails_7.0.gemfile
allow_failures: true
env:
BUNDLE_GEMFILE: "${{ matrix.gemfile }}"
ALLOW_FAILURES: "${{ matrix.allow_failures }}"
REDIS_URL: "redis://localhost:6379/4"
DATABASE_URL: ${{ (startsWith(matrix.gemfile,'gemfiles/que') && 'postgres://postgres:postgres@localhost:5432/que_test') || 'sqlite3:db/combustion_test.sqlite'}}
continue-on-error: ${{ endsWith(matrix.ruby, 'head') || matrix.ruby == 'debug' }}
# Service containers to run with `container-job`
services:
redis:
image: redis:latest
ports:
- 6379:6379
# Label used to access the service container
postgres:
# Docker Hub image
image: postgres:9.4
# Provide the password for postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_DB: que_test
# Set health checks to wait until postgres has started
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- name: Set up Ruby
# To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
# change this to (see https://github.com/ruby/setup-ruby#versioning):
# uses: ruby/setup-ruby@v1
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: bundle exec rake || $ALLOW_FAILURES