44 push :
55 paths : &paths
66 - .github/workflows/behat.yml
7- - bin/tools/behat
8- - src/Behat/**
9- - tests/Behat/**
10- - behat.yml
11- - composer.json
7+ - src/Test/Behat/**
128 pull_request :
139 paths : *paths
1410 schedule :
1511 - cron : ' 0 0 1,16 * *'
1612
13+ defaults :
14+ run :
15+ shell : bash
16+ working-directory : ./src/Test/Behat
17+
1718concurrency :
1819 group : ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
1920 cancel-in-progress : true
2021
2122jobs :
2223 behat :
23- name : P:${{ matrix.php }}, S:${{ matrix.symfony }}${{ matrix.deps == 'lowest' && ' (lowest)' || '' }}
24+ name : Behat - P:${{ matrix.php }}, S:${{ matrix.symfony }}${{ matrix.deps == 'lowest' && ' (lowest)' || '' }}
2425 runs-on : ubuntu-latest
2526 strategy :
2627 fail-fast : false
2728 matrix :
2829 php : [ 8.3, 8.5 ]
2930 symfony : [ 6.4.*, 7.4.* ]
3031 deps : [ highest, lowest ]
31- env :
32- DATABASE_URL : ' sqlite:///%kernel.project_dir%/var/data.db'
33- USE_DAMA_DOCTRINE_TEST_BUNDLE : 1
34- USE_PHP_84_LAZY_OBJECTS : 1
35- MONGO_URL : ' '
3632 steps :
3733 - name : Checkout code
3834 uses : actions/checkout@v3
@@ -51,16 +47,12 @@ jobs:
5147 - name : Install dependencies
5248 uses : ramsey/composer-install@v2
5349 with :
50+ working-directory : " src/Test/Behat"
5451 dependency-versions : ${{ matrix.deps }}
5552 composer-options : --prefer-dist
5653 env :
5754 SYMFONY_REQUIRE : ${{ matrix.symfony }}
5855
59- - name : Install Behat
60- run : composer bin behat update ${{ matrix.deps == 'lowest' && '--prefer-lowest' || '' }} --prefer-dist
61- env :
62- SYMFONY_REQUIRE : ${{ matrix.symfony }}
63-
6456 - name : " Main test suite: reset DB at scenario level, with Dama support"
6557 run : vendor/bin/behat --colors -vvv
6658
8476
8577 - name : Reset DB disabled
8678 run : vendor/bin/behat --colors -vvv --profile=reset-disabled
79+
80+ phpunit :
81+ name : PHPUnit - P:${{ matrix.php }}, S:${{ matrix.symfony }}${{ matrix.deps == 'lowest' && ' (lowest)' || '' }}
82+ runs-on : ubuntu-latest
83+ strategy :
84+ fail-fast : false
85+ matrix :
86+ php : [ 8.3, 8.5 ]
87+ symfony : [ 6.4.*, 7.4.* ]
88+ deps : [ highest, lowest ]
89+ steps :
90+ - name : Checkout code
91+ uses : actions/checkout@v3
92+
93+ - name : Setup PHP
94+ uses : shivammathur/setup-php@v2
95+ with :
96+ php-version : ${{ matrix.php }}
97+ coverage : none
98+ tools : flex
99+
100+ - name : Add the polyfill compatible with Doctrine ^2.16
101+ if : ${{ matrix.deps == 'lowest' }}
102+ run : composer require --dev symfony/polyfill-php80:^1.16 --no-update
103+
104+ - name : Install dependencies
105+ uses : ramsey/composer-install@v2
106+ with :
107+ working-directory : " src/Test/Behat"
108+ dependency-versions : ${{ matrix.deps }}
109+ composer-options : --prefer-dist
110+ env :
111+ SYMFONY_REQUIRE : ${{ matrix.symfony }}
112+
113+ - name : Run tests
114+ run : vendor/bin/phpunit
115+
116+ phpstan :
117+ name : PhpStan
118+ runs-on : ubuntu-latest
119+ steps :
120+ - name : Checkout code
121+ uses : actions/checkout@v3
122+
123+ - name : Setup PHP
124+ uses : shivammathur/setup-php@v2
125+ with :
126+ php-version : 8.5
127+ coverage : none
128+ tools : flex
129+
130+ - name : Install dependencies
131+ uses : ramsey/composer-install@v2
132+ with :
133+ working-directory : " src/Test/Behat"
134+ composer-options : --prefer-dist
135+ env :
136+ SYMFONY_REQUIRE : 7.4.*
137+
138+ - name : Install PHPStan
139+ run : composer bin phpstan install
140+
141+ - name : Run PHPStan
142+ run : ../../../bin/tools/phpstan/vendor/phpstan/phpstan/phpstan
0 commit comments