Skip to content

Commit 0ebdce1

Browse files
authored
simplify test-suite config (#464)
1 parent 0f46ee8 commit 0ebdce1

11 files changed

+102
-405
lines changed

.phpstan-dba-pdo-mysql.cache

Lines changed: 14 additions & 238 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config/dba.neon

Lines changed: 1 addition & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
includes:
22
- stubFiles.neon
33
- extensions.neon
4+
- rules.neon
45

56
parameters:
67
featureToggles:
@@ -9,83 +10,3 @@ parameters:
910
- mysqli_result
1011
- Doctrine\DBAL\Result
1112
- Doctrine\DBAL\Statement
12-
13-
services:
14-
-
15-
class: staabm\PHPStanDba\Rules\SyntaxErrorInPreparedStatementMethodRule
16-
tags: [phpstan.rules.rule]
17-
arguments:
18-
classMethods:
19-
- 'Doctrine\DBAL\Connection::executeQuery'
20-
- 'Doctrine\DBAL\Connection::executeCacheQuery'
21-
- 'Doctrine\DBAL\Connection::executeStatement'
22-
- 'Doctrine\DBAL\Connection::fetchAssociative'
23-
- 'Doctrine\DBAL\Connection::fetchNumeric'
24-
- 'Doctrine\DBAL\Connection::fetchOne'
25-
- 'Doctrine\DBAL\Connection::fetchAllNumeric'
26-
- 'Doctrine\DBAL\Connection::fetchAllAssociative'
27-
- 'Doctrine\DBAL\Connection::fetchAllKeyValue'
28-
- 'Doctrine\DBAL\Connection::fetchAllAssociativeIndexed'
29-
- 'Doctrine\DBAL\Connection::fetchFirstColumn'
30-
- 'Doctrine\DBAL\Connection::iterateNumeric'
31-
- 'Doctrine\DBAL\Connection::iterateAssociative'
32-
- 'Doctrine\DBAL\Connection::iterateKeyValue'
33-
- 'Doctrine\DBAL\Connection::iterateAssociativeIndexed'
34-
- 'Doctrine\DBAL\Connection::iterateColumn'
35-
- 'Doctrine\DBAL\Connection::executeUpdate' # deprecated in doctrine
36-
37-
-
38-
class: staabm\PHPStanDba\Rules\PdoStatementExecuteMethodRule
39-
tags: [phpstan.rules.rule]
40-
41-
-
42-
class: staabm\PHPStanDba\Rules\SyntaxErrorInQueryMethodRule
43-
tags: [phpstan.rules.rule]
44-
arguments:
45-
classMethods:
46-
- 'PDO::query#0'
47-
- 'PDO::prepare#0'
48-
- 'mysqli::query#0'
49-
- 'mysqli::execute_query#0'
50-
- 'Doctrine\DBAL\Connection::query#0' # deprecated in doctrine
51-
- 'Doctrine\DBAL\Connection::exec#0' # deprecated in doctrine
52-
53-
-
54-
class: staabm\PHPStanDba\Rules\SyntaxErrorInQueryFunctionRule
55-
tags: [phpstan.rules.rule]
56-
arguments:
57-
functionNames:
58-
- 'Deployer\runMysqlQuery#0'
59-
- 'mysqli_query#1'
60-
- 'mysqli_execute_query#1'
61-
62-
-
63-
class: staabm\PHPStanDba\Rules\QueryPlanAnalyzerRule
64-
tags: [phpstan.rules.rule]
65-
arguments:
66-
classMethods:
67-
# prepared statement methods
68-
- 'Doctrine\DBAL\Connection::executeQuery#0'
69-
- 'Doctrine\DBAL\Connection::executeCacheQuery#0'
70-
- 'Doctrine\DBAL\Connection::executeStatement#0'
71-
- 'Doctrine\DBAL\Connection::fetchAssociative#0'
72-
- 'Doctrine\DBAL\Connection::fetchNumeric#0'
73-
- 'Doctrine\DBAL\Connection::fetchOne#0'
74-
- 'Doctrine\DBAL\Connection::fetchAllNumeric#0'
75-
- 'Doctrine\DBAL\Connection::fetchAllAssociative#0'
76-
- 'Doctrine\DBAL\Connection::fetchAllKeyValue#0'
77-
- 'Doctrine\DBAL\Connection::fetchAllAssociativeIndexed#0'
78-
- 'Doctrine\DBAL\Connection::fetchFirstColumn#0'
79-
- 'Doctrine\DBAL\Connection::iterateNumeric#0'
80-
- 'Doctrine\DBAL\Connection::iterateAssociative#0'
81-
- 'Doctrine\DBAL\Connection::iterateKeyValue#0'
82-
- 'Doctrine\DBAL\Connection::iterateAssociativeIndexed#0'
83-
- 'Doctrine\DBAL\Connection::iterateColumn#0'
84-
- 'Doctrine\DBAL\Connection::executeUpdate#0' # deprecated in doctrine
85-
# regular statements
86-
- 'PDO::query#0'
87-
- 'PDO::prepare#0'
88-
- 'mysqli::query#0'
89-
- 'mysqli::execute_query#0'
90-
- 'Doctrine\DBAL\Connection::query#0' # deprecated in doctrine
91-
- 'Doctrine\DBAL\Connection::exec#0' # deprecated in doctrine

0 commit comments

Comments
 (0)