From 006ffbeb18730d6f1100869a2da9110ebb5748fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Niedzielski?= Date: Mon, 14 Aug 2023 13:51:06 +0200 Subject: [PATCH] Added PHPStan --- .github/workflows/ci.yaml | 2 +- phpstan-baseline-8.0-specific.neon | 6 ++++++ phpstan-baseline.neon.php | 4 ++++ 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 phpstan-baseline-8.0-specific.neon diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index b18290b8..b67e1b65 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -40,7 +40,7 @@ jobs: php: - '7.4' - '8.0' - - '8.1' + - '8.2' steps: - uses: actions/checkout@v3 diff --git a/phpstan-baseline-8.0-specific.neon b/phpstan-baseline-8.0-specific.neon new file mode 100644 index 00000000..ca11aa1d --- /dev/null +++ b/phpstan-baseline-8.0-specific.neon @@ -0,0 +1,6 @@ +parameters: + ignoreErrors: + - + message: "#^Parameter \\#2 \\$value of function ini_set expects string, int given\\.$#" + count: 2 + path: tests/lib/Output/Generator/FieldTypeHashGeneratorBaseTest.php diff --git a/phpstan-baseline.neon.php b/phpstan-baseline.neon.php index d78e8e43..a0283663 100644 --- a/phpstan-baseline.neon.php +++ b/phpstan-baseline.neon.php @@ -13,6 +13,10 @@ $includes[] = __DIR__ . '/phpstan-baseline-8.0.neon'; } +if (PHP_VERSION_ID > 80000 && PHP_VERSION_ID < 80100) { + $includes[] = __DIR__ . '/phpstan-baseline-8.0-specific.neon'; +} + $config = []; $config['includes'] = $includes;