molych/php-project-lvl2

View on GitHub
.github/workflows/main.yml

Summary

Maintainability
Test Coverage
name: PHP-CI

on:
  - push

jobs:
  build:

    runs-on: ubuntu-latest

    steps:
       
      - uses: actions/checkout@v2

      - name: Setup PHP
        uses: shivammathur/setup-php@v2
        with:
          php-version: '7.4'

      - name: Install
        run: make install
  
      - name: Run linter
        run: make lint

      - name: Run test & publish code coverage
        uses: paambaati/codeclimate-action@v2.6.0
        # Add Code Climate secret key
        env:
          CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }}
        with:
          coverageCommand: make test-coverage
          coverageLocations: ${{github.workplace}}/build/logs/clover.xml:clover
          debug: true