Skip to content

feat: export a Sorbet RBI declaring the ActiveRecord::Base mixin #292

feat: export a Sorbet RBI declaring the ActiveRecord::Base mixin

feat: export a Sorbet RBI declaring the ActiveRecord::Base mixin #292

Workflow file for this run

name: Tests
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:14
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: journaled_test
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
strategy:
fail-fast: false
matrix:
ruby: ['3.2', '3.3', '3.4']
gemfile:
- gemfiles/rails_7_2.gemfile
- gemfiles/rails_8_0.gemfile
database: ['sqlite3', 'postgresql']
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
- uses: ruby/setup-ruby@e34163cd15f4bb403dcd72d98e295997e6a55798 # v1
env:
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Setup database
if: matrix.database == 'postgresql'
env:
DATABASE_ADAPTER: postgresql
DATABASE_USER: postgres
DATABASE_PASSWORD: postgres
DATABASE_HOST: localhost
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
run: |
bundle exec rake db:create db:schema:load
- name: Run tests
env:
BUNDLE_GEMFILE: ${{ matrix.gemfile }}
DATABASE_ADAPTER: ${{ matrix.database }}
DATABASE_USER: postgres
DATABASE_PASSWORD: postgres
DATABASE_HOST: localhost
run: bundle exec rake spec