update ruby to 2.6.0 #226
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow uses actions that are not certified by GitHub. | |
# They are provided by a third-party and are governed by | |
# separate terms of service, privacy policy, and support | |
# documentation. | |
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake | |
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby | |
name: Run test and rubocop | |
on: | |
pull_request: | |
branches: [production] | |
jobs: | |
test: | |
runs-on: ubuntu-20.04 | |
services: | |
db: | |
image: postgres:11 | |
env: | |
POSTGRES_PASSWORD: postgres | |
ports: ['5432:5432'] | |
options: >- | |
--health-cmd pg_isready | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 2.5.3 | |
- run: | | |
bundle install --without production development | |
- env: | |
RAILS_ENV: test | |
PGHOST: localhost | |
PGPASSWORD: postgres | |
run: | | |
cp config/database.yml.travis config/database.yml | |
cp .env.default .env | |
bundle exec rake db:setup | |
sudo apt-get install texlive-latex-base | |
bundle exec rake test | |
rubocop: | |
name: rubocop | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Setup Ruby and install gems | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 2.5.3 | |
- run: | | |
bundle install --without production development | |
- name: Run rubocop | |
run: | | |
bundle exec rubocop -D -f simple |