The script already has PHPUnit setup to produce code coverage reports, but Xdebug is not installed during the process, thus code coverage reports are not actually generated.
I am new to the pipelines and these scripts - and also to Xdebug, so someone with more experience may be able to correct me, however I wrestled with this for a day and finally got the code coverage working by installing Xdebug via Pecl and then enabling it with docker-php-ext-enable xdebug
.
Without doing this, running the tests would just issue the below issue. It does not cause the job to fail.
Xdebug installation docs: https://xdebug.org/docs/install
I've been using this and it has been working a treat.