Skip to content

Commit

Permalink
ci: do not use deprecated actions/cache (#218)
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks authored Dec 11, 2024
1 parent 6c46d1f commit d3bf4f0
Showing 1 changed file with 3 additions and 20 deletions.
23 changes: 3 additions & 20 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
name: Test

env:
COMPOSER_VERSION: "2"
COMPOSER_CACHE: "${{ github.workspace }}/.composer-cache"

on:
push:
branches:
Expand All @@ -20,7 +16,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Start MySQL
run: sudo systemctl start mysql.service
Expand All @@ -37,27 +33,14 @@ jobs:
with:
elasticsearch version: '7.5.0'

- name: Set standard 10up cache directories
run: |
composer config -g cache-dir "${{ env.COMPOSER_CACHE }}"
- name: Prepare composer cache
uses: actions/cache@v2
with:
path: ${{ env.COMPOSER_CACHE }}
key: composer-${{ env.COMPOSER_VERSION }}-${{ hashFiles('**/composer.lock') }}
restore-keys: |
composer-${{ env.COMPOSER_VERSION }}-
- name: Set PHP version
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
coverage: none
tools: composer:v1

- name: Install dependencies
run: composer install
- name: Install PHP Dependencies
uses: ramsey/composer-install@3.0.0

- name: Setup WP Tests
run: |
Expand Down

0 comments on commit d3bf4f0

Please sign in to comment.