Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,33 @@ parameters:
message: '~^Class Doctrine\\DBAL\\(Platforms\\SqlitePlatform|Schema\\SqliteSchemaManager) referenced with incorrect case: Doctrine\\DBAL\\(Platforms\\SQLitePlatform|Schema\\SQLiteSchemaManager)\.$~'
count: 24

# remove once https://github.com/phpstan/phpstan/issues/11488 is fixed
-
path: 'src/Persistence/Sql/Oracle/Query.php'
identifier: nullCoalesce.variable
message: '~^Variable \$operator on left side of \?\? is never defined\.$~'
count: 1
-
path: 'src/Persistence/Sql/Oracle/Query.php'
identifier: instanceof.alwaysFalse
message: '~^Instanceof between \*NEVER\* and Atk4\\Data\\Field will always evaluate to false\.$~'
count: 2
-
path: 'src/Persistence/Sql/Oracle/Query.php'
identifier: booleanAnd.alwaysFalse
message: '~^Result of && is always false\.$~'
count: 3
-
path: 'src/Persistence/Sql/Query.php'
identifier: identical.alwaysFalse
message: '~^Strict comparison using === between \*NEVER\* and 3 will always evaluate to false\.$~'
count: 1
-
path: 'src/Persistence/Sql/Query.php'
identifier: variable.undefined
message: '~^(Undefined variable: \$(operator|value)|Variable \$value might not be defined\.)$~'
count: 3

# TODO these rules are generated, this ignores should be fixed in the code
# for src/Schema/TestCase.php
-
Expand Down
2 changes: 1 addition & 1 deletion src/Persistence/Sql/Oracle/ExpressionTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ protected function escapeStringLiteral(string $value): string
/**
* Like mb_str_split() function, but split by length in bytes.
*
* @return array<string>
* @return list<string>
*/
private function splitLongString(string $value, int $lengthBytes): array
{
Expand Down
2 changes: 1 addition & 1 deletion tests/Schema/TestCaseTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ public function testLogQuery(): void
/**
* @param int<1, 12> $month
*
* @return array<mixed>
* @return array<mixed, mixed>
*/
private function createAssertSameExportUnorderedTestRow(int $month): array
{
Expand Down