name: RSpec tests on: - pull_request jobs: tests: runs-on: ubuntu-latest strategy: matrix: ruby-version: - '2.7' - '3.0' - 'head' activerecord-gemfile: - 'ar_5_latest' - 'ar_6_latest' - 'ar_7_latest' ar_lazy_preload-gemfile: - 'ar_lazy_preload_0.6.1' - 'ar_lazy_preload_master' exclude: - ruby-version: 'head' activerecord-gemfile: 'ar_5_latest' - ruby-version: 'head' activerecord-gemfile: 'ar_5_latest' - ruby-version: '3.0' activerecord-gemfile: 'ar_5_latest' - ruby-version: '3.0' activerecord-gemfile: 'ar_5_latest' - activerecord-gemfile: 'ar_7_latest' ar_lazy_preload-gemfile: 'ar_lazy_preload_0.6.1' env: ACTIVERECORD_GEMFILE: ${{ matrix.activerecord-gemfile }} AR_LAZY_PRELOAD_GEMFILE: ${{ matrix.ar_lazy_preload-gemfile }} steps: - uses: actions/checkout@v3 - name: Set up Ruby ${{ matrix.ruby-version }} uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby-version }} bundler-cache: true - name: Install dependencies run: bundle install - name: Run Core tests run: bundle exec rspec spec/n1_loader_spec.rb - name: Run ActiveRecord tests run: bundle exec rspec spec/n1_loader_spec.rb spec/activerecord_spec.rb - name: Run ArLazyPreload tests run: bundle exec rspec spec/n1_loader_spec.rb spec/activerecord_spec.rb spec/ar_lazy_preload_spec.rb