Skip to content

remove codeclimate badges #60

remove codeclimate badges

remove codeclimate badges #60

Workflow file for this run

name: Test
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby:
- '3.1'
- '3.2'
- '3.3'
rails:
- '7.0'
- '7.1'
- '7.2'
- '8.0'
- '8.1'
exclude:
- ruby: '3.1' # rails 8 requires ruby >= 3.2
rails: '8.0'
- ruby: '3.1' # rails 8.1 requires ruby >= 3.2
rails: '8.1'
services:
postgres:
image: postgres:13
env:
POSTGRES_PASSWORD: 'password'
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
steps:
- uses: actions/checkout@v2
- name: Setup Ruby ${{ matrix.ruby }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Setup Bundler
run: |
gem update --system --no-doc
gem install bundler --no-doc
bundle config set path "vendor/bundle"
- name: Install Gems for Rails ${{ matrix.rails }}
env:
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
run: |
bundle check || bundle install --jobs 4 --retry 3
- name: Run Test Suite (sqlite)
env:
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
run: |
bundle exec rake
- name: Run Test Suite (postgres)
env:
BUNDLE_GEMFILE: gemfiles/${{ matrix.rails }}.gemfile
run: |
PGPASSWORD=password psql -h localhost -U postgres -c 'create database active_record_distinct_on_test;'
DATABASE_URL='postgresql://postgres:password@localhost/active_record_distinct_on_test' bundle exec rake