Skip to content

Commit b262118

Browse files
committed
Fix running workflow by upgrading the reusable workflow
1 parent 9485974 commit b262118

File tree

1 file changed

+40
-46
lines changed

1 file changed

+40
-46
lines changed

.github/workflows/check.yml

Lines changed: 40 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,51 @@
1+
name: "Code check"
2+
13
on:
2-
pull_request:
4+
workflow_call:
35
push:
46
branches:
5-
- "*"
6-
- "!gh-pages"
7+
- "main"
8+
9+
pull_request:
10+
paths:
11+
- "src/**"
12+
- "tests/**"
13+
- "composer.json"
14+
- "ecs.php"
15+
- "rector.php"
16+
- "phpstan.neon"
17+
- "phpunit.xml"
18+
19+
concurrency:
20+
group: php-get-typed-value-check-${{ github.ref }}
21+
cancel-in-progress: true
722

823
jobs:
9-
run:
10-
uses: wrk-flow/reusable-workflows/.github/workflows/php-check.yml@main
24+
code:
25+
name: "Code check"
26+
uses: wrk-flow/reusable-workflows/.github/workflows/php-check.yml@7562253bdc3769847417e3476b501e7126f5d2c0
1127
secrets: inherit
12-
with:
13-
gistID: 11b884c06da0bf9116ae763d23438ecb
14-
15-
without-laravel:
16-
name: "Tests without laravel"
17-
runs-on: "ubuntu-latest"
1828

29+
tests:
30+
name: "Run tests"
1931
strategy:
20-
fail-fast: false
2132
matrix:
22-
php-version:
23-
- "8.1"
24-
dependencies:
25-
- "lowest"
26-
- "highest"
27-
28-
steps:
29-
- name: "Checkout"
30-
uses: actions/checkout@v3
31-
32-
- name: "Install PHP"
33-
uses: "shivammathur/setup-php@v2"
34-
with:
35-
php-version: "${{ matrix.php-version }}"
36-
37-
- name: "Install lowest dependencies"
38-
if: ${{ matrix.dependencies == 'lowest' }}
39-
run: "composer update --prefer-lowest --no-interaction --no-progress"
40-
41-
- name: "Install highest dependencies"
42-
if: ${{ matrix.dependencies == 'highest' }}
43-
run: "composer update --no-interaction --no-progress"
44-
45-
- name: "Remove Laravel"
46-
run: "composer remove --dev laravel/framework orchestra/testbench"
47-
48-
- name: "Remove Laravel tests"
49-
run: "rm -rf tests/Laravel"
50-
51-
- name: "Tests"
52-
id: tests
53-
continue-on-error: false
54-
run: |
55-
vendor/bin/phpunit
33+
phpVersion: [ "8.1", "8.2" ]
34+
uses: wrk-flow/reusable-workflows/.github/workflows/php-tests.yml@91be5bbf6aca80f54548ec1bddc7c9ced6efb78f
35+
with:
36+
gistID: ${{ vars.GIST_ID }}
37+
gistOnPhpVersion: "8.2"
38+
phpVersion: "${{ matrix.phpVersion }}"
39+
secrets: inherit
5640

41+
tests_no_frameworks:
42+
name: "Run tests without Frameworks"
43+
strategy:
44+
matrix:
45+
phpVersion: [ "8.1", "8.2" ]
46+
uses: wrk-flow/reusable-workflows/.github/workflows/php-tests.yml@91be5bbf6aca80f54548ec1bddc7c9ced6efb78f
47+
with:
48+
phpVersion: "${{ matrix.phpVersion }}"
49+
composerRemove: "--dev laravel/framework orchestra/testbench"
50+
dirsRemove: "tests/Laravel"
5751

0 commit comments

Comments
 (0)