From 6e3788247a4a4ff45f955d80bb822cf7ef694dd6 Mon Sep 17 00:00:00 2001 From: Joris Ros Date: Sun, 24 Nov 2024 14:07:57 +0100 Subject: [PATCH] feat: add php 8.3 and add Symfony stable versions --- .github/workflows/psalm.yml | 14 +++++++++++--- .github/workflows/tests.yaml | 16 +++++++++++++--- composer.json | 8 ++++---- src/BoilerPlateBundle.php | 2 +- 4 files changed, 29 insertions(+), 11 deletions(-) diff --git a/.github/workflows/psalm.yml b/.github/workflows/psalm.yml index 7c6226b..eab5178 100644 --- a/.github/workflows/psalm.yml +++ b/.github/workflows/psalm.yml @@ -1,6 +1,11 @@ name: Integration - -on: [push] +run-name: Run psalm of ${{ github.event.pull_request.title }} +on: + pull_request: + types: + - opened + - synchronize + - reopened jobs: psalm: @@ -8,7 +13,10 @@ jobs: strategy: matrix: operating-system: [ubuntu-latest] - php-versions: ['8.1','8.2'] + php-versions: + - '8.1' + - '8.2' + - '8.3' name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }} steps: - uses: actions/checkout@v3 diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 759d89a..1824175 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -1,13 +1,21 @@ name: run-tests -run-name: ${{ github.actor }} made changes -on: [push] +run-name: Run phpunit tests of ${{ github.event.pull_request.title }} +on: + pull_request: + types: + - opened + - synchronize + - reopened jobs: run: runs-on: ${{ matrix.operating-system }} strategy: matrix: operating-system: [ubuntu-latest] - php-versions: ['8.1','8.2'] + php-versions: + - '8.1' + - '8.2' + - '8.3' name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }} steps: - name: Checkout @@ -22,6 +30,8 @@ jobs: run: php -v - name: Composer uses: php-actions/composer@v6 + with: + args: "--ignore-platform-req=php" - name: Tests uses: php-actions/phpunit@v3 with: diff --git a/composer.json b/composer.json index 19bb68f..10f0681 100644 --- a/composer.json +++ b/composer.json @@ -20,10 +20,10 @@ } ], "require": { - "php": ">=8.1", - "symfony/http-kernel": "^5.4|^6.0", - "symfony/dependency-injection": "^5.4|^6.0", - "symfony/config": "^5.4|^6.0" + "php": "^8.1|^8.2|^8.3", + "symfony/http-kernel": "^5.4|^6.4|^7.1", + "symfony/dependency-injection": "^5.4|^6.4|^7.1", + "symfony/config": "^5.4|^6.4|^7.1" }, "require-dev": { "phpunit/phpunit": "^9.6|^10.0", diff --git a/src/BoilerPlateBundle.php b/src/BoilerPlateBundle.php index 3c8ff59..45e42c3 100644 --- a/src/BoilerPlateBundle.php +++ b/src/BoilerPlateBundle.php @@ -14,6 +14,6 @@ public function getContainerExtension(): ?ExtensionInterface return new BoilerPlateBundleExtension(); } - return $this->extension; + return $this->extension ?: null; } } \ No newline at end of file