Commit bda10a7
committed
GH Actions/tests: prevent warning about outdated configuration being used
The configuration file specification has undergone changes in PHPUnit 9.3 and 10.0.
Most notably:
* In PHPUnit 9.3, the manner of specifying the code coverage configuration has changed.
* In PHPUnit 10.0, a significant number of attributes of the `<phpunit>` element were removed or renamed.
When running PHPUnit 10 with a PHPUnit 9 style configuration file, PHPUnit 10 can show a warning:
```
There was 1 PHPUnit test runner deprecation:
1) Your XML configuration validates against a deprecated schema. Migrate your XML configuration using "--migrate-configuration"!
```
The `--migrate-configuration` command can upgrade a configuration for the changes in the format made in PHPUnit 9.3 and 10.0/10.1, but some of the changes in the configuration format in PHPUnit 10 don't have one-on-one replacements and/or are not taken into account.
This commit is a way to "future proof" the test workflow a little by preventing that PHPUnit warning from potentially failing a build in the future.
Notes:
* If/when PHPUnit 11 starts to be supported, the bash condition will need updating to also recognize PHPUnit 11.
* The `--migrate-configuration` script will fail (exit code `1`) if no update is needed, like if one of the repos would have a PHPUnit 10-style config file.
To prevent this from failing the test job, I'm explicitly setting `continue-on-error: true`.1 parent 2fc4bbd commit bda10a7
1 file changed
Lines changed: 20 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
242 | 262 | | |
243 | 263 | | |
244 | 264 | | |
| |||
0 commit comments