spickermann/deep_hash_transformer

View on GitHub
.github/workflows/CI.yml

Summary

Maintainability
Test Coverage
name: CI

on:
  push:
    branches: [ main ]
  pull_request:
    branches: [ main ]

jobs:
  test:
    runs-on: ubuntu-latest

    strategy:
      matrix:
        ruby: [3.3.0, 3.2.3, 3.1.4, 3.0.6]

    name: CI Ruby ${{ matrix.ruby }}
    steps:
      - name: Checkout Code
        uses: actions/checkout@v4
      - name: Setup Ruby
        uses: ruby/setup-ruby@v1
        with:
          ruby-version: ${{ matrix.ruby }}
      - name: Install Gems
        run: bundle install
      - name: RSpec
        run: bundle exec rspec
      - name: Standard
        run: bundle exec standardrb
      - name: Coveralls
        if: ${{ matrix.ruby == '3.3.0' }}
        continue-on-error: true
        uses: coverallsapp/github-action@v2
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
      - name: Codacy Coverage
        if: ${{ matrix.ruby == '3.3.0' }}
        uses: codacy/codacy-coverage-reporter-action@v1
        with:
          project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
      - name: Code Climate
        if: ${{ matrix.ruby == '3.3.0' }}
        continue-on-error: true
        uses: paambaati/codeclimate-action@v5.0.0
        env:
          CC_TEST_REPORTER_ID: ${{ secrets.CODE_CLIMATE_TOKEN }}
        with:
          coverageCommand: bundle exec rspec
          coverageLocations: ${{ github.workspace }}/coverage/coverage.json:simplecov