Gem specific changes from https://www.prioritized.net/blog/testing-ruby-gems-with-github-actions
This commit is contained in:
parent
19c8d7481b
commit
612734b7b7
16
.github/workflows/ruby.yml
vendored
16
.github/workflows/ruby.yml
vendored
@ -4,7 +4,7 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches: [ master, develop ]
|
branches: [ master, develop ]
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ develop ]
|
branches: "*"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
@ -12,6 +12,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
strategy:
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- rails-version: "5.2.0"
|
- rails-version: "5.2.0"
|
||||||
@ -24,8 +25,19 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
RAILS_VERSION: ${{ matrix.rails-version }}
|
RAILS_VERSION: ${{ matrix.rails-version }}
|
||||||
uses: ruby/setup-ruby@v1
|
uses: ruby/setup-ruby@v1
|
||||||
|
# with:
|
||||||
|
# bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
||||||
|
- name: Generate lockfile
|
||||||
|
run: bundle lock
|
||||||
|
- name: Cache dependencies
|
||||||
|
uses: actions/cache@v1
|
||||||
with:
|
with:
|
||||||
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
path: vendor/bundle
|
||||||
|
key: bundle-${{ hashFiles('Gemfile.lock') }}
|
||||||
|
- name: Install dependencies
|
||||||
|
run: bundle config path vendor/bundle
|
||||||
|
run: gem install bundler --conservative
|
||||||
|
run: bundle check || bundle install
|
||||||
- name: Install JS dependencies
|
- name: Install JS dependencies
|
||||||
run: yarn
|
run: yarn
|
||||||
- name: Create database
|
- name: Create database
|
||||||
|
Loading…
x
Reference in New Issue
Block a user