name: CI on: [push, pull_request] jobs: RSpec: runs-on: ubuntu-latest env: RAILS_ENV: test services: postgres: image: postgres:11 env: POSTGRES_USER: postgres POSTGRES_PASSWORD: password POSTGRES_DB: alchemy_pg_search_test ports: ["5432:5432"] options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 steps: - uses: actions/checkout@v2.3.4 - name: Set up Ruby uses: ruby/setup-ruby@v1 with: ruby-version: 3.2 bundler-cache: true - name: Prepare database run: bundle exec rake alchemy:spec:prepare - name: Run tests run: bundle exec rspec