Skip to content

Commit

Permalink
Add CI (#3)
Browse files Browse the repository at this point in the history
* Upgrade gemfile.lock to remove deprecation message

* Add CI for Ruby rspec

* Add CI for Rubocop

* Simplify CI for tests

* Set Ruby version to 3.2 in CI for tests

* Bring back the matrix for CI

* Set Ruby 3.1 and head for Ruby test CI

* Set Ruby 3.1 for linter CI

* Update ruby workflow to run rspec

* Update the github workflow triggers
  • Loading branch information
ahangarha authored Dec 18, 2023
1 parent bda8631 commit 775d2ac
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 1 deletion.
26 changes: 26 additions & 0 deletions .github/workflows/rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Rubocop

on:
push:
branches:
- 'main'
pull_request:

jobs:
rubocop:
name: Rubocop
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
ruby: ['3.1']

steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true

- name: Ruby rubocop
run: bundle exec rubocop
26 changes: 26 additions & 0 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Ruby specs

on:
push:
branches:
- 'main'
pull_request:

jobs:
ruby:
name: Ruby
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
ruby: ['3.1', head]

steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true

- name: Run RSpec
run: bundle exec rspec
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -105,4 +105,4 @@ DEPENDENCIES
yard

BUNDLED WITH
2.1.4
2.4.22

0 comments on commit 775d2ac

Please sign in to comment.