Skip to content

Commit

Permalink
Config Github Actions for Rspec
Browse files Browse the repository at this point in the history
  • Loading branch information
joaocv3 committed Oct 29, 2020
1 parent bf8bfb3 commit e19ba09
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/unit_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Ruby Unit Tests

on:
push:
branches: [ "*" ]
pull_request:
branches: [ "*" ]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
ruby: [ '2.5', '2.6', '2.7' ]

name: Ruby ${{ matrix.ruby }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Cache gems
uses: actions/cache@v2
env:
cache-name: cache-gems
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Set bundle config path
run: |
bundle config path vendor/bundle
- name: Install dependencies
run: |
bundle install
- name: Ruby Unit tests
run: |
bundle exec rspec

0 comments on commit e19ba09

Please sign in to comment.