Skip to content

Commit 392868f

Browse files
committed
Skip unreliable test
1 parent fcb67c2 commit 392868f

File tree

1 file changed

+20
-18
lines changed

1 file changed

+20
-18
lines changed

tests/Type/Doctrine/Query/QueryResultTypeWalkerTest.php

+20-18
Original file line numberDiff line numberDiff line change
@@ -1274,33 +1274,35 @@ public function getTestData(): iterable
12741274
',
12751275
];
12761276

1277-
yield 'locate function' => [
1278-
$this->constantArray([
1279-
[new ConstantIntegerType(1), $this->uintStringified()],
1280-
[new ConstantIntegerType(2), TypeCombinator::addNull($this->uintStringified())],
1281-
[new ConstantIntegerType(3), TypeCombinator::addNull($this->uintStringified())],
1282-
[new ConstantIntegerType(4), $this->uintStringified()],
1283-
]),
1284-
'
1277+
if (PHP_VERSION_ID > 70300) {
1278+
yield 'locate function' => [
1279+
$this->constantArray([
1280+
[new ConstantIntegerType(1), $this->uintStringified()],
1281+
[new ConstantIntegerType(2), TypeCombinator::addNull($this->uintStringified())],
1282+
[new ConstantIntegerType(3), TypeCombinator::addNull($this->uintStringified())],
1283+
[new ConstantIntegerType(4), $this->uintStringified()],
1284+
]),
1285+
'
12851286
SELECT LOCATE(m.stringColumn, m.stringColumn, 0),
12861287
LOCATE(m.stringNullColumn, m.stringColumn, 0),
12871288
LOCATE(m.stringColumn, m.stringNullColumn, 0),
12881289
LOCATE(\'f\', \'foo\', 0)
12891290
FROM QueryResult\Entities\Many m
12901291
',
1291-
null,
1292-
InstalledVersions::satisfies(new VersionParser(), 'doctrine/dbal', '>=3.4')
1293-
? null
1294-
: (
1292+
null,
1293+
InstalledVersions::satisfies(new VersionParser(), 'doctrine/dbal', '>=3.4')
1294+
? null
1295+
: (
12951296
PHP_VERSION_ID >= 80100
12961297
? 'strpos(): Passing null to parameter #2 ($needle) of type string is deprecated'
12971298
: (
1298-
PHP_VERSION_ID >= 70300 && PHP_VERSION_ID < 80000
1299-
? 'strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior'
1300-
: null
1301-
)
1302-
),
1303-
];
1299+
PHP_VERSION_ID >= 70300 && PHP_VERSION_ID < 80000
1300+
? 'strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior'
1301+
: null
1302+
)
1303+
),
1304+
];
1305+
}
13041306

13051307
yield 'lower function' => [
13061308
$this->constantArray([

0 commit comments

Comments
 (0)