Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions .github/workflows/php-cs-on-changes.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
name: PHP Coding Standards - PR Changed Files

on:
pull_request:
paths:
- "**.php"
- .github/workflows/php-cs-on-changes.yml
pull_request: { }
# run on all PRs

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -16,7 +14,7 @@ jobs:
timeout-minutes: 15
strategy:
matrix:
php: [7.4, 8.3]
php: [ 7.4, 8.3 ]
name: Code sniff (PHP ${{ matrix.php }}, WP Latest)
permissions:
contents: read
Expand Down Expand Up @@ -45,3 +43,7 @@ jobs:
- name: Run PHPCS
if: steps.changed-files.outputs.any_changed == 'true'
run: vendor/bin/phpcs-changed --warning-severity=0 -s --git --git-base ${{ github.event.pull_request.base.sha }} ${{ steps.changed-files.outputs.all_changed_files }}

- name: Skip PHPCS - No PHP Files Updated
if: steps.changed-files.outputs.any_changed != 'true'
run: echo "No PHP files changed; skipping PHPCS checks."
23 changes: 4 additions & 19 deletions .github/workflows/php-unit-tests.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,6 @@
name: PHP Unit Tests

on:
push:
branches:
- trunk
- develop
paths:
- "**.php"
- composer.json
- composer.lock
- .github/workflows/php-unit-tests.yml
pull_request:
paths:
- "**.php"
- composer.json
- composer.lock
- .github/workflows/php-unit-tests.yml
on: [ push, pull_request ] # Run on all pushes and PRs

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -30,9 +15,9 @@ jobs:
WP_TESTS_DIR: "/tmp/wordpress/tests/phpunit"
strategy:
matrix:
php: [7.4, 8.3]
wp-version: [latest]
wc-version: [latest]
php: [ 7.4, 8.3 ]
wp-version: [ latest ]
wc-version: [ latest ]

steps:
- name: Install SVN
Expand Down