Skip to content

Commit 610e294

Browse files
committed
excludePaths integration test
1 parent 91a917e commit 610e294

File tree

4 files changed

+36
-0
lines changed

4 files changed

+36
-0
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,9 @@ jobs:
220220
composer install
221221
cp ../../phpstan vendor/bin/phpstan
222222
vendor/bin/phpstan analyse -l 8 src/
223+
- |
224+
cd e2e/excludePaths
225+
../../phpstan analyse
223226
include:
224227
- php-version: 8.0
225228
operating-system: ubuntu-latest

e2e/excludePaths/phpstan.neon

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
parameters:
2+
level: 8
3+
paths:
4+
- src
5+
excludePaths:
6+
analyse:
7+
- src/thirdparty

e2e/excludePaths/src/foo.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
namespace App;
4+
5+
class Foo extends \ThirdParty\Bar
6+
{
7+
8+
public function doFoo(): void
9+
{
10+
$this->doBar();
11+
}
12+
13+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
namespace ThirdParty;
4+
5+
class Bar
6+
{
7+
8+
public function doBar()
9+
{
10+
return;
11+
}
12+
13+
}

0 commit comments

Comments
 (0)