Skip to content

Commit

Permalink
Integrate Code Climate into rspec GitHub Action
Browse files Browse the repository at this point in the history
  • Loading branch information
darronschall committed May 24, 2024
1 parent 757022b commit 67f478a
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/rspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ on:

jobs:
build:
env:
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
COVERAGE: true

runs-on: ubuntu-latest
name: Ruby ${{ matrix.ruby }}
strategy:
Expand All @@ -27,5 +31,16 @@ jobs:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
cache-version: 1

- name: Setup Code Climate Test Reporter
run: |
sudo curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
sudo chmod +x ./cc-test-reporter
./cc-test-reporter before-build
- name: Run RSpec
run: bundle exec rake spec

- name: Coverage Report
run: |
./cc-test-reporter after-build --coverage-input-type simplecov --exit-code $?

0 comments on commit 67f478a

Please sign in to comment.