Skip to content

Commit

Permalink
Added a GitHub Actions job to run tests (issue #9).
Browse files Browse the repository at this point in the history
  • Loading branch information
postmodern committed May 5, 2024
1 parent 4745a83 commit 5148a58
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 18 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: CI

on: [ push, pull_request ]

jobs:
# rubocop linting
rubocop:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.0
- name: Install dependencies
run: bundle install --jobs 4 --retry 3
- name: Run rubocop
run: bundle exec rubocop --parallel

tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby:
- '3.0'
- '3.1'
- '3.2'
# - jruby
- truffleruby
name: Ruby ${{ matrix.ruby }}
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Install dependencies
run: bundle install --jobs 4 --retry 3
- name: Run tests
run: bundle exec rake test

18 changes: 0 additions & 18 deletions .github/workflows/rubocop.yml

This file was deleted.

0 comments on commit 5148a58

Please sign in to comment.