What's new in Infection 0.10.0
Aug 11, 2018
Before upgrading, make sure you know about backward incompatible changes.
- Infection now requires PHP 7.1+. If you can’t for some reason upgrade and stuck on 7.0, don’t worry, you can still use 0.9.0.
- PHAR file is no longer signed with OpenSSL built-in algorithm. See below.
Infection now can be installed by Phive - The PHAR Installation and Verification Environment. Since Phive requires GPG signing, we dropped built-in PHP OpenSSL signing. For each release we will upload
infection.phar.asc. Previously downloaded
infection.phar.pubkey can be deleted.
With Phive you can install Infection as
phive install infection
You can still download the PHAR file manually, the process is almost the same:
gpg --keyserver hkps.pool.sks-keyservers.net --recv-keys 493B4AA0
You should see something like:
gpg: Signature made Sun Aug 5 21:46:42 2018 +03
There was a reorganization of taps in Homebrew PHP and not all previously existed packages have been moved to the Homebrew core, including Infection.
We created our custom repository so you can continue using
brew to install Infection:
brew tap infection/homebrew-infection
Thanks Pierre du Plessis for helping and maintaining it!
Infection now outputs information about how much time and memory did it take to run mutation testing:
When you have hundreds or even thousands of mutations, and especially when you use
--threads, it’s quite difficult to read log file because each time mutations were logged in a random order (due to parallel processes).
Now mutations are sorted by file path and then by line of the mutation:
3) Domain/Model/Goal/Goal.php:82 [M] MethodCallRemoval
These two mutators will remove function or method calls that are not part of another statement (e.g.
loop), or get assigned to a value.
This should help make sure that your tests are covering side effects caused by an action.
- $this->eventDispatcher->dispatch(new InitialTestSuiteStarted());
Helps to check you are correctly testing the logic of
- preg_match('/a/', 'abc', $foo);
This mutator removes condition part of
Coalesce operator (
$a ?? $b ->
private function getListeners(string $eventName): array