11name : Unit Tests
22
3+ defaults :
4+ run :
5+ shell : bash
6+
37on :
48 push :
59 paths-ignore :
@@ -18,14 +22,15 @@ concurrency:
1822
1923jobs :
2024 php :
21- runs-on : ubuntu-latest
25+ runs-on : ${{ matrix.os || ' ubuntu-latest' }}
2226 strategy :
2327 fail-fast : false
2428 matrix :
2529 php-version : ['8.1', '8.2', '8.3', '8.4']
2630 dependency-version : ['']
2731 symfony-version : ['']
2832 minimum-stability : ['stable']
33+ os : ['']
2934 include :
3035 # dev packages (probably not needed to have multiple such jobs)
3136 - minimum-stability : ' dev'
3641 # LTS version of Symfony
3742 - php-version : ' 8.1'
3843 symfony-version : ' 6.4.*'
44+ - php-version : ' 8.1'
45+ symfony-version : ' 6.4.*'
46+ os : ' windows-latest'
3947
4048 env :
4149 SYMFONY_REQUIRE : ${{ matrix.symfony-version || '>=5.4' }}
@@ -78,13 +86,24 @@ jobs:
7886 run : |
7987 source .github/workflows/.utils.sh
8088
81- echo "$PACKAGES" | xargs -n1 | parallel -j +3 "_run_task {} \
82- '(cd src/{} \
83- && $COMPOSER_MIN_STAB \
84- && $COMPOSER_UP \
85- && if [ {} = LiveComponent ]; then install_property_info_for_version \"${{ matrix.php-version }}\" \"${{ matrix.minimum-stability }}\"; fi \
86- && $PHPUNIT)'"
87-
89+ if [ "${{ matrix.os }}" = "windows-latest" ]; then
90+ # parallel is not available on Windows, so we need to run the tests sequentially
91+ for PACKAGE in $PACKAGES; do
92+ _run_task $PACKAGE \
93+ '(cd src/$PACKAGE \
94+ && $COMPOSER_MIN_STAB \
95+ && $COMPOSER_UP \
96+ && if [ $PACKAGE = LiveComponent ]; then install_property_info_for_version \"${{ matrix.php-version }}\" \"${{ matrix.minimum-stability }}\"; fi \
97+ && $PHPUNIT)'
98+ done
99+ else
100+ echo "$PACKAGES" | xargs -n1 | parallel -j +3 "_run_task {} \
101+ '(cd src/{} \
102+ && $COMPOSER_MIN_STAB \
103+ && $COMPOSER_UP \
104+ && if [ {} = LiveComponent ]; then install_property_info_for_version \"${{ matrix.php-version }}\" \"${{ matrix.minimum-stability }}\"; fi \
105+ && $PHPUNIT)'"
106+ fi
88107 js :
89108 runs-on : ubuntu-latest
90109 steps :
0 commit comments