diff --git a/.github/dependabot.yml b/.github/dependabot.yml index e76d591..7142c55 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -2,10 +2,10 @@ version: 2 updates: # Maintain dependencies for GitHub Actions - #- package-ecosystem: "github-actions" - # directory: "/" - # schedule: - # interval: "monthly" + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "monthly" # Maintain dependencies for Composer - package-ecosystem: "composer" diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 445ceb6..98da931 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,7 +4,6 @@ on: push: branches: [ master ] pull_request: - branches: [ master ] jobs: lint: @@ -17,46 +16,36 @@ jobs: with: php-version: '7.3' - - name: 'Get composer cache directory' - id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" - - - name: 'Cache dependencies' - uses: actions/cache@v2 + - uses: "ramsey/composer-install@v3" with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- - - - name: Install dependencies - run: composer update --prefer-dist + composer-options: "--prefer-dist" - name: Code Sniffer run: vendor/bin/phpcs --standard=psr2 src/ test: runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + php-version: + - "7.4" + - "8.0" + - "8.1" + - "8.2" + - "8.3" + steps: - uses: actions/checkout@v2 - name: 'Setup PHP' uses: shivammathur/setup-php@v2 with: - php-version: '7.3' - - - name: 'Get composer cache directory' - id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + php-version: "${{ matrix.php-version }}" - - name: 'Cache dependencies' - uses: actions/cache@v2 + - uses: "ramsey/composer-install@v3" with: - path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- - - - name: Install dependencies - run: composer update --prefer-dist + composer-options: "--prefer-dist" - name: Run tests run: vendor/bin/phpunit --coverage-text --coverage-clover=coverage.clover