Updated the Rakefile to publish packages to the Github registry. #96
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check the test coverage of the code. | |
# | |
# This runs as a Github Action. Note that the Coverall repository token is | |
# injected as an environment variable, instead of being read from | |
#`.coveralls.yaml` config file. | |
# | |
# See https://github.com/marketplace/actions/coveralls-github-action | |
# | |
# Also see | |
name: Test Coveralls | |
on: ["push", "pull_request"] | |
env: | |
COVERAGE: true | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
jobs: | |
test: | |
name: Ruby ${{ matrix.ruby }} | |
strategy: | |
fail-fast: false | |
matrix: | |
ruby: ["2.7", "3.0", "3.1", "3.2", "3.3"] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Clone Repository | |
uses: actions/checkout@v2 | |
- name: Setup Ruby and bundler dependencies | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: ${{ matrix.ruby }} | |
bundler-cache: true | |
- name: Run Ruby Tests | |
run: bundle exec rake clobber test:coverage | |
- name: Coveralls | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
flag-name: ruby-${{ matrix.ruby }} | |
parallel: true | |
finish: | |
needs: test | |
runs-on: ubuntu-latest | |
steps: | |
- name: Coveralls Finished | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
parallel-finished: true |