diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 672771ad18b..1d1a863f27f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,6 +12,45 @@ env: COMPOSER_ROOT_VERSION: "0.12.x-dev" jobs: + lint: + name: "lint" + + runs-on: "ubuntu-latest" + + strategy: + matrix: + php-version: + - "7.1" + - "7.2" + - "7.3" + - "7.4" + + steps: + - name: "Checkout" + uses: "actions/checkout@v2.0.0" + + - name: "Install PHP" + uses: "shivammathur/setup-php@1.8.2" + with: + coverage: "none" + php-version: "${{ matrix.php-version }}" + + - name: "Validate Composer" + run: "composer validate" + + - name: "Cache dependencies" + uses: "actions/cache@v1.1.2" + with: + path: "~/.composer/cache" + key: "php-${{ matrix.php-version }}-composer-${{ hashFiles('**/composer.json') }}" + restore-keys: "php-${{ matrix.php-version }}-composer-" + + - name: "Install dependencies" + run: "composer update --no-interaction --no-progress --no-suggest" + + - name: "Lint" + run: "vendor/bin/phing lint" + coding-standards: name: "Coding Standard" diff --git a/tests/PHPStan/Rules/Variables/data/isset-native-property-types.php b/tests/PHPStan/Rules/Variables/data/isset-native-property-types.php index 1d93d3f647b..f493c1fac6e 100644 --- a/tests/PHPStan/Rules/Variables/data/isset-native-property-types.php +++ b/tests/PHPStan/Rules/Variables/data/isset-native-property-types.php @@ -1,4 +1,4 @@ -= 7.4 namespace IssetNativePropertyTypes; diff --git a/tests/PHPStan/Rules/Variables/data/variable-certainty-null-assign.php b/tests/PHPStan/Rules/Variables/data/variable-certainty-null-assign.php index d0d2b7c9274..8500b140634 100644 --- a/tests/PHPStan/Rules/Variables/data/variable-certainty-null-assign.php +++ b/tests/PHPStan/Rules/Variables/data/variable-certainty-null-assign.php @@ -1,4 +1,4 @@ -= 7.4 function (): void { $scalar = 3;