Skip to content

Commit 96015f3

Browse files
committed
Fix CommandHelper tests
1 parent 84b0934 commit 96015f3

File tree

3 files changed

+10
-27
lines changed

3 files changed

+10
-27
lines changed

tests/PHPStan/Command/CommandHelperTest.php

Lines changed: 8 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -166,23 +166,12 @@ public function dataParameters(): array
166166
[
167167
__DIR__ . '/relative-paths/root.neon',
168168
[
169-
'bootstrap' => __DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'here.php',
170169
'bootstrapFiles' => [
171170
realpath(__DIR__ . '/../../../stubs/runtime/ReflectionUnionType.php'),
172171
realpath(__DIR__ . '/../../../stubs/runtime/ReflectionAttribute.php'),
173172
realpath(__DIR__ . '/../../../stubs/runtime/Attribute.php'),
174173
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'here.php',
175174
],
176-
'autoload_files' => [
177-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'here.php',
178-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'test' . DIRECTORY_SEPARATOR . 'there.php',
179-
__DIR__ . DIRECTORY_SEPARATOR . 'up.php',
180-
],
181-
'autoload_directories' => [
182-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src',
183-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths',
184-
realpath(__DIR__ . '/../../../') . '/conf',
185-
],
186175
'scanFiles' => [
187176
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'here.php',
188177
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'test' . DIRECTORY_SEPARATOR . 'there.php',
@@ -197,17 +186,20 @@ public function dataParameters(): array
197186
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src',
198187
],
199188
'memoryLimitFile' => __DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . '.memory_limit',
200-
'excludes_analyse' => [
201-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src',
202-
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src' . DIRECTORY_SEPARATOR . '*' . DIRECTORY_SEPARATOR . 'data',
203-
'*/src/*/data',
189+
'excludePaths' => [
190+
'analyseAndScan' => [
191+
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src',
192+
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'src' . DIRECTORY_SEPARATOR . '*' . DIRECTORY_SEPARATOR . 'data',
193+
'*/src/*/data',
194+
],
195+
'analyse' => [],
204196
],
205197
],
206198
],
207199
[
208200
__DIR__ . '/relative-paths/nested/nested.neon',
209201
[
210-
'autoload_files' => [
202+
'scanFiles' => [
211203
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'nested' . DIRECTORY_SEPARATOR . 'here.php',
212204
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'nested' . DIRECTORY_SEPARATOR . 'test' . DIRECTORY_SEPARATOR . 'there.php',
213205
__DIR__ . DIRECTORY_SEPARATOR . 'relative-paths' . DIRECTORY_SEPARATOR . 'up.php',

tests/PHPStan/Command/relative-paths/nested/nested.neon

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
parameters:
2-
autoload_files:
2+
scanFiles:
33
- here.php
44
- test/there.php
55
- ../up.php
Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,6 @@
11
parameters:
2-
bootstrap: here.php
32
bootstrapFiles:
43
- here.php
5-
autoload_files:
6-
- here.php
7-
- test/there.php
8-
- ../up.php
9-
autoload_directories:
10-
- src
11-
- .
12-
- %rootDir%/conf
134
scanFiles:
145
- here.php
156
- test/there.php
@@ -21,7 +12,7 @@ parameters:
2112
paths:
2213
- src
2314
memoryLimitFile: .memory_limit
24-
excludes_analyse:
15+
excludePaths:
2516
- src
2617
- src/*/data
2718
- */src/*/data

0 commit comments

Comments
 (0)