Skip to content

Commit 78474dd

Browse files
committed
Update infection builder
1 parent cd10d3a commit 78474dd

File tree

2 files changed

+30
-6
lines changed

2 files changed

+30
-6
lines changed

infection.json5

+10-2
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,11 @@
9898
"LogicalAndSingleSubExprNegation": true,
9999
"LogicalLowerAnd": true,
100100
"LogicalLowerOr": true,
101-
"LogicalNot": true,
101+
"LogicalNot": {
102+
"ignore": [
103+
"Nexus\\Password\\Hash\\Pbkdf2Hash::verify"
104+
]
105+
},
102106
"LogicalOr": true,
103107
"LogicalOrAllSubExprNegation": true,
104108
"LogicalOrNegation": true,
@@ -138,7 +142,11 @@
138142
"SpreadRemoval": true,
139143
"Ternary": true,
140144
"This": true,
141-
"Throw_": true,
145+
"Throw_": {
146+
"ignore": [
147+
"Nexus\\Encryption\\Key::__unserialize"
148+
]
149+
},
142150
"TrueValue": {
143151
"ignore": [
144152
"Nexus\\Collection\\Collection::generateDiffHashTable"

tools/src/InfectionConfigBuilder.php

+20-4
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
use Infection\Mutator\ProfileList;
1717
use Nexus\Clock\SystemClock;
1818
use Nexus\Collection\Collection;
19+
use Nexus\Encryption\Key;
20+
use Nexus\Password\Hash\Pbkdf2Hash;
1921
use Nexus\Password\Hash\SodiumHash;
2022

2123
/**
@@ -64,13 +66,27 @@ final class InfectionConfigBuilder
6466
Collection::class.'::filterWithKey',
6567
Collection::class.'::reject',
6668
],
67-
'CastInt' => [SystemClock::class],
69+
'CastInt' => [
70+
SystemClock::class,
71+
],
6872
'CastString' => [
6973
Collection::class.'::toArrayKey',
7074
],
71-
'Division' => [SystemClock::class],
72-
'LogicalAnd' => [SodiumHash::class.'::valid'],
73-
'ModEqual' => [SystemClock::class],
75+
'Division' => [
76+
SystemClock::class,
77+
],
78+
'LogicalAnd' => [
79+
SodiumHash::class.'::valid',
80+
],
81+
'LogicalNot' => [
82+
Pbkdf2Hash::class . '::verify'
83+
],
84+
'ModEqual' => [
85+
SystemClock::class,
86+
],
87+
'Throw_' => [
88+
Key::class.'::__unserialize',
89+
],
7490
'TrueValue' => [
7591
Collection::class.'::generateDiffHashTable',
7692
],

0 commit comments

Comments
 (0)