Skip to content

Commit 041abf0

Browse files
committed
set phpstan to lvl 8
1 parent 71a6d24 commit 041abf0

File tree

5 files changed

+10
-2
lines changed

5 files changed

+10
-2
lines changed

composer.json

+1
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
"post-autoload-dump": "@composer run prepare",
5151
"prepare": "@php vendor/bin/testbench package:discover --ansi",
5252
"analyse": "vendor/bin/phpstan analyse",
53+
"baseline": "vendor/bin/phpstan analyse --generate-baseline --memory-limit=2G",
5354
"test": "vendor/bin/pest",
5455
"test-coverage": "vendor/bin/pest --coverage",
5556
"format": "vendor/bin/pint"

phpstan-baseline.neon

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
parameters:
2+
ignoreErrors:
3+
-
4+
message: '#^Called ''env'' outside of the config directory which returns null when the config is cached, use ''config''\.$#'
5+
identifier: larastan.noEnvCallsOutsideOfConfig
6+
count: 3
7+
path: config/harvest-sdk.php

phpstan.neon.dist

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ includes:
22
- phpstan-baseline.neon
33

44
parameters:
5-
level: 5
5+
level: 8
66
paths:
77
- src
88
- config

src/Harvest.php

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ public function resolveBaseUrl(): string
1717
{
1818
return 'https://api.harvestapp.com/v2';
1919
}
20+
2021
protected function defaultHeaders(): array
2122
{
2223
return [

tests/HarvestServiceProviderTest.php

-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
app(Harvest::class);
3636
})->throws('No Harvest account ID was provided. Make sure to set the `HARVEST_ACCOUNT_ID` environment variable.');
3737

38-
3938
it('throws an exception if access_token is missing', function () {
4039
config()->set('harvest-sdk', [
4140
'account_id' => 'fake-account-id',

0 commit comments

Comments
 (0)