jeyroik/toncenter-php-sdk

View on GitHub
.github/workflows/php.yml

Summary

Maintainability
Test Coverage
name: PHP Composer

on: [push]

jobs:
  build:

    runs-on: ubuntu-latest

    strategy:
      matrix:
        php-version:
          - "8.1"
    env:
      TONC__TOKEN: ${{ secrets.TONCENTER_TOKEN }}
      
    steps:
    - uses: actions/checkout@v2

    - name: "Install PHP with extensions"
      uses: "shivammathur/setup-php@v2"
      with:
       php-version: "${{ matrix.php-version }}"
       coverage: "pcov"

    - name: Validate composer.json and composer.lock
      run: composer validate

    - name: Install dependencies
      run: composer install --prefer-dist --no-progress --no-suggest

    - name: Run test suites
      run: composer run-script test

    - name: "Send code coverage report to Codecov.io"
      env:
        CODECOV_TOKEN: "${{ secrets.CODECOV_TOKEN }}"
      run: "bash <(curl -s https://codecov.io/bash) || true"