Closed chrispage1 closed 1 year ago
So to test this further, I've spun up a blank php:8.2-fpm-alpine
image by running docker run -it -v "$(pwd)":/var/www:z php:8.2-fpm-alpine /bin/sh
Once inside, I've run ./vendor/bin/pest --parallel
and it's run absolutely no problem, very strange... I don't suppose anyone else has come across this?
After much debugging, I found the problem... before running pest, I was installing packages using composer as below:
composer install -o --no-interaction --no-plugins --no-scripts --ignore-platform-req=ext-*
The --no-plugins
was preventing pest from setting up its own binary and was somehow deferring to PHPUnit. After removing this option from composer install, we're back and the full power of PEST is being utilised.
+ ./vendor/bin/pest --parallel --compact
............................................................................
............................................................................
............................................................................
............................................................................
............................................................................
.....................................
Tests: 409 passed (1014 assertions)
Duration: 32.69s
Parallel: 8 processes
Loving the pest project, it's really changing the way I test so thank you for that!
However, I've come across a bit of a strange issue. I have retrofitted PEST to a project that previously had a load of tests and have rewritten some. This works great and I can run
./vendor/bin/pest --parallel
on my machine no problem.However when pushing it up to a deployment pipeline, I get the below -
This worked perfectly when it was previously
php artisan test --parallel
. Any ideas why parallel seems to be an unknown option on my deployment pipeline? The tests are running within aphp:8.2-fpm-alpine
image.Thanks, Chris.