.github/workflows/postgresql.yml in by_star-4.0.0 vs .github/workflows/postgresql.yml in by_star-4.0.1

- old
+ new

@@ -1,99 +1,99 @@ -name: PostgreSQL tests - -on: - # Trigger the workflow on push or pull request, - # but only for the master branch - push: - branches: - - master - pull_request: - branches: - - master - -jobs: - postgresql: - strategy: - fail-fast: false - matrix: - ruby_version: [3.0, 2.7, 2.6, 2.5, jruby] - gemfile: - [ - spec/gemfiles/Gemfile.rails50, - spec/gemfiles/Gemfile.rails51, - spec/gemfiles/Gemfile.rails52, - spec/gemfiles/Gemfile.rails60, - spec/gemfiles/Gemfile.rails61, - spec/gemfiles/Gemfile.rails, - ] - exclude: - # Ruby 3.x is not supported by Rails 5.2.x - - ruby_version: 3.0 - gemfile: spec/gemfiles/Gemfile.rails52 - # Ruby 3.x is not supported by Rails 5.1.x - - ruby_version: 3.0 - gemfile: spec/gemfiles/Gemfile.rails51 - # Ruby 3.x is not supported by Rails 5.0.x - - ruby_version: 3.0 - gemfile: spec/gemfiles/Gemfile.rails50 - - - ruby_version: 2.6 - gemfile: spec/gemfiles/Gemfile.rails32 - - # Ruby 2.6.x is not supported by Rails main - - ruby_version: 2.6 - gemfile: spec/gemfiles/Gemfile.rails - - # Ruby 2.5.x is not supported by Rails main - - ruby_version: 2.5 - gemfile: spec/gemfiles/Gemfile.rails - - # Ruby 2.4.x is not supported by Rails main - - ruby_version: 2.4 - gemfile: spec/gemfiles/Gemfile.rails - # Ruby 2.4.x is not supported by Rails 6.1.x - - ruby_version: 2.4 - gemfile: spec/gemfiles/Gemfile.rails61 - # Ruby 2.4.x is not supported by Rails 6.0.x - - ruby_version: 2.4 - gemfile: spec/gemfiles/Gemfile.rails60 - # Ruby 2.3.x is not supported by Rails 6.1.x - - ruby_version: 2.3 - gemfile: spec/gemfiles/Gemfile.rails61 - # Ruby 2.3.x is not supported by Rails main - - ruby_version: 2.3 - gemfile: spec/gemfiles/Gemfile.rails - # Ruby 2.3.x is not supported by Rails 6.0.x - - ruby_version: 2.3 - gemfile: spec/gemfiles/Gemfile.rails60 - # JRuby is not supported by Rails main - - ruby_version: jruby - gemfile: spec/gemfiles/Gemfile.rails - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - - name: Set up Ruby - uses: ruby/setup-ruby@master - with: - ruby-version: ${{ matrix.ruby_version }} - - - uses: harmon758/postgresql-action@v1 - with: - postgresql version: '11' - - - name: Start PostgreSQL - run: | - sudo service postgresql start - sudo -u postgres createuser --superuser "$USER" - createdb by_star_test - - - name: Build and test with Rake - env: - BUNDLE_GEMFILE: ${{ matrix.gemfile }} - DB: "postgres" - run: | - gem install bundler - bundle install --jobs 4 --retry 3 - bundle exec rake +name: PostgreSQL tests + +on: + # Trigger the workflow on push or pull request, + # but only for the master branch + push: + branches: + - master + pull_request: + branches: + - master + +jobs: + postgresql: + strategy: + fail-fast: false + matrix: + ruby_version: [3.0, 2.7, 2.6, 2.5, jruby] + gemfile: + [ + spec/gemfiles/Gemfile.rails50, + spec/gemfiles/Gemfile.rails51, + spec/gemfiles/Gemfile.rails52, + spec/gemfiles/Gemfile.rails60, + spec/gemfiles/Gemfile.rails61, + spec/gemfiles/Gemfile.rails, + ] + exclude: + # Ruby 3.x is not supported by Rails 5.2.x + - ruby_version: 3.0 + gemfile: spec/gemfiles/Gemfile.rails52 + # Ruby 3.x is not supported by Rails 5.1.x + - ruby_version: 3.0 + gemfile: spec/gemfiles/Gemfile.rails51 + # Ruby 3.x is not supported by Rails 5.0.x + - ruby_version: 3.0 + gemfile: spec/gemfiles/Gemfile.rails50 + + - ruby_version: 2.6 + gemfile: spec/gemfiles/Gemfile.rails32 + + # Ruby 2.6.x is not supported by Rails main + - ruby_version: 2.6 + gemfile: spec/gemfiles/Gemfile.rails + + # Ruby 2.5.x is not supported by Rails main + - ruby_version: 2.5 + gemfile: spec/gemfiles/Gemfile.rails + + # Ruby 2.4.x is not supported by Rails main + - ruby_version: 2.4 + gemfile: spec/gemfiles/Gemfile.rails + # Ruby 2.4.x is not supported by Rails 6.1.x + - ruby_version: 2.4 + gemfile: spec/gemfiles/Gemfile.rails61 + # Ruby 2.4.x is not supported by Rails 6.0.x + - ruby_version: 2.4 + gemfile: spec/gemfiles/Gemfile.rails60 + # Ruby 2.3.x is not supported by Rails 6.1.x + - ruby_version: 2.3 + gemfile: spec/gemfiles/Gemfile.rails61 + # Ruby 2.3.x is not supported by Rails main + - ruby_version: 2.3 + gemfile: spec/gemfiles/Gemfile.rails + # Ruby 2.3.x is not supported by Rails 6.0.x + - ruby_version: 2.3 + gemfile: spec/gemfiles/Gemfile.rails60 + # JRuby is not supported by Rails main + - ruby_version: jruby + gemfile: spec/gemfiles/Gemfile.rails + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Set up Ruby + uses: ruby/setup-ruby@master + with: + ruby-version: ${{ matrix.ruby_version }} + + - uses: harmon758/postgresql-action@v1 + with: + postgresql version: '11' + + - name: Start PostgreSQL + run: | + sudo service postgresql start + sudo -u postgres createuser --superuser "$USER" + createdb by_star_test + + - name: Build and test with Rake + env: + BUNDLE_GEMFILE: ${{ matrix.gemfile }} + DB: "postgres" + run: | + gem install bundler + bundle install --jobs 4 --retry 3 + bundle exec rake