From 39db5f17bee9190691ee3b1092427e8ad5b84ab2 Mon Sep 17 00:00:00 2001 From: Hennadii Shvedko Date: Fri, 3 Nov 2023 16:30:01 +0100 Subject: [PATCH] github actions --- .github/workflows/continuous-integration.yml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.github/workflows/continuous-integration.yml b/.github/workflows/continuous-integration.yml index f77abc8..a69deef 100644 --- a/.github/workflows/continuous-integration.yml +++ b/.github/workflows/continuous-integration.yml @@ -35,10 +35,19 @@ jobs: php-version: "${{ matrix.php-version }}" ini-values: memory_limit=-1 - - name: "Install dependencies" - uses: "ramsey/composer-install@2.2.0" + - name: "Validate composer.json and composer.lock" + run: "composer validate" + - name: "Get composer cache directory" + id: "composer-cache" + run: "echo \"::set-output name=dir::$(composer config cache-files-dir)\"" + - name: "Cache composer dependencies" + uses: "actions/cache@v1" with: - dependency-versions: "${{ matrix.dependencies }}" + path: "${{ steps.composer-cache.outputs.dir }}" + key: "${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}" + restore-keys: "${{ runner.os }}-composer-" + - name: "Install Composer dependencies" + run: "composer install" - name: "Tests" run: "vendor/bin/phpunit tests/ --colors"