FoveaCentral/google_maps_geocoder

View on GitHub
.github/workflows/test.yml

Summary

Maintainability
Test Coverage
# Download the latest Ruby patch versions, install dependencies, and run tests.
name: test
on:
  push:
    paths-ignore:
      - '**.md'
      - '**.txt'
jobs:
  test:
    environment: staging
    runs-on: ubuntu-latest
    name: Ruby ${{ matrix.ruby-version }}
    strategy:
      matrix:
        ruby-version: ['3.0', 3.1, 3.2, 3.3]
    steps:
    - name: Checkout code
      uses: actions/checkout@v4
    - name: Set up Ruby ${{ matrix.ruby-version }}
      uses: ruby/setup-ruby@v1
      with:
        ruby-version: ${{ matrix.ruby-version }}
        bundler-cache: true # 'bundle install' and cache
    - name: Run tests
      env:
        GOOGLE_MAPS_API_KEY: ${{ secrets.GOOGLE_MAPS_API_KEY }}
      run: bundle exec rake
    - name: Send Code Climate coverage
      uses: aktions/codeclimate-test-reporter@v1
      with:
        codeclimate-test-reporter-id: ${{ secrets.CC_TEST_REPORTER_ID }}
        command: after-build --coverage-input-type lcov
    - name: Send Coveralls coverage
      uses: coverallsapp/github-action@master
      with:
        github-token: ${{ secrets.GITHUB_TOKEN }}
    - name: Run RuboCop
      run: bundle exec rubocop
    - name: Run Inch
      run: bundle exec inch --pedantic