From 86450917038c594563f2dccc2ece0eba3f951847 Mon Sep 17 00:00:00 2001 From: kylekatarnls Date: Tue, 2 Dec 2025 23:07:51 +0100 Subject: [PATCH 1/2] Use all-array before/after --- src/JsPhpize/Nodes/Dyiade.php | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/JsPhpize/Nodes/Dyiade.php b/src/JsPhpize/Nodes/Dyiade.php index ac0f322..2578cbe 100644 --- a/src/JsPhpize/Nodes/Dyiade.php +++ b/src/JsPhpize/Nodes/Dyiade.php @@ -26,17 +26,13 @@ class Dyiade extends Value */ protected $operator; - public function __construct($operator, Value $leftHand, Value $rightHand, array $before = null, array $after = null) + public function __construct($operator, Value $leftHand, Value $rightHand, array $before = [], array $after = []) { $this->operator = $operator; $this->leftHand = $leftHand; $this->rightHand = $rightHand; - if ($before !== null) { - $this->before = $before; - } - if ($after !== null) { - $this->after = $after; - } + $this->before = $before; + $this->after = $after; } public function getReadVariables() From 97c7ea0fcb1c931683c48d906067b9b997af8190 Mon Sep 17 00:00:00 2001 From: kylekatarnls Date: Tue, 2 Dec 2025 23:24:42 +0100 Subject: [PATCH 2/2] Update coverage config --- .github/workflows/tests.yml | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 7eb519e..ea18ad7 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,8 +13,17 @@ jobs: strategy: fail-fast: false matrix: - php: ['7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3'] - setup: ['lowest', 'stable', 'next'] + php: ['7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4', '8.5'] + setup: ['stable'] + include: + - php: '7.0' + setup: 'lowest' + - php: '7.0' + setup: 'next' + - php: '8.5' + setup: 'lowest' + - php: '8.5' + setup: 'next' name: PHP ${{ matrix.php }} - ${{ matrix.setup }} @@ -42,15 +51,6 @@ jobs: ${{ matrix.php >= 8.1 && 'composer require --no-update phpunit/phpunit:^8.5.14 --no-interaction' || '' }} composer update --prefer-dist ${{ matrix.setup != 'next' && format('--prefer-{0}', matrix.setup) || '' }} --no-progress --no-suggest ${{ matrix.php >= 8.1 && '--ignore-platform-req=php' || '' }} - - name: Code Climate Test Reporter Preparation - if: matrix.php == '7.4' && matrix.setup == 'stable' - run: | - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter; - chmod +x ./cc-test-reporter; - ./cc-test-reporter before-build; - env: - CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} - - name: Run test suite run: | if [[ ${MATRIX_CONFIG} == "7.4-stable" ]]; then @@ -62,11 +62,14 @@ jobs: MATRIX_CONFIG: ${{ matrix.php }}-${{ matrix.setup }} - name: Code Climate Test Reporter - if: ${{ matrix.php == '7.4' && matrix.setup == 'stable' && env.CC_TEST_REPORTER_ID != '' }} - run: ./cc-test-reporter after-build --exit-code 0 - env: - CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} + if: ${{ matrix.php == '7.4' && matrix.setup == 'stable' }} + uses: qltysh/qlty-action/coverage@v2 + with: + token: ${{ secrets.QLTY_COVERAGE_TOKEN }} + files: clover.xml - name: Coverage if: matrix.php == '7.4' && matrix.setup == 'stable' - run: bash <(curl -s https://codecov.io/bash) + uses: codecov/codecov-action@v5 + with: + token: ${{ secrets.CODECOV_TOKEN }}