Skip to content

Commit

Permalink
Enhancement: Split compiling and testing Phar
Browse files Browse the repository at this point in the history
  • Loading branch information
localheinz committed Feb 5, 2024
1 parent 7d20697 commit de0529a
Showing 1 changed file with 30 additions and 7 deletions.
37 changes: 30 additions & 7 deletions .github/workflows/integrate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -220,14 +220,13 @@ jobs:
- name: "Show info about phpunit-slow-test-detector.phar with humbug/box"
run: ".phive/box info ${{ env.PHPUNIT_SLOW_TEST_DETECTOR_PHAR }} --ansi --list"

- name: "Install ${{ matrix.dependencies }} dependencies for running phar tests with composer"
uses: "ergebnis/.github/actions/composer/[email protected].0"
- name: "Upload Phar"
uses: "actions/[email protected].0"
with:
dependencies: "${{ matrix.dependencies }}"
working-directory: "test/Phar/Version10/"

- name: "Run phar tests with phpunit/phpunit"
run: "test/Phar/Version10/vendor/bin/phpunit --colors=always --configuration=test/Phar/Version10/phpunit.xml"
name: "phpunit-slow-test-detector-phar"
overwrite: true
path: "${{ env.PHPUNIT_SLOW_TEST_DETECTOR_PHAR }}"
retention-days: 1

dependency-analysis:
name: "Dependency Analysis"
Expand Down Expand Up @@ -451,6 +450,9 @@ jobs:

timeout-minutes: 5

needs:
- "compile-phar"

strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -510,6 +512,9 @@ jobs:
php-version: "8.3"
dependencies: "highest"

env:
PHPUNIT_SLOW_TEST_DETECTOR_PHAR: ".build/phar/phpunit-slow-test-detector.phar"

steps:
- name: "Checkout"
uses: "actions/[email protected]"
Expand Down Expand Up @@ -591,3 +596,21 @@ jobs:
- name: "Run end-to-end tests with phpunit/phpunit:11.0.x-dev"
if: "matrix.phpunit-version == '11.0.x-dev'"
run: "vendor/bin/phpunit --colors=always --configuration=test/EndToEnd/Version11/phpunit.xml"

- name: "Download Phar"
if: "matrix.phpunit-version == '10.0.0'"
uses: "actions/[email protected]"
with:
name: "phpunit-slow-test-detector-phar"
path: "${{ env.PHPUNIT_SLOW_TEST_DETECTOR_PHAR }}"

- name: "Install ${{ matrix.dependencies }} dependencies for running phar tests with composer"
if: "matrix.phpunit-version == '10.0.0'"
uses: "ergebnis/.github/actions/composer/[email protected]"
with:
dependencies: "${{ matrix.dependencies }}"
working-directory: "test/Phar/Version10/"

- name: "Run phar tests with phpunit/phpunit:10.0.0"
if: "matrix.phpunit-version == '10.0.0'"
run: "test/Phar/Version10/vendor/bin/phpunit --colors=always --configuration=test/Phar/Version10/phpunit.xml"

0 comments on commit de0529a

Please sign in to comment.