From 8167a7206c29156819802e5713083e386de1a282 Mon Sep 17 00:00:00 2001 From: JanHuang <384099566@qq.com> Date: Mon, 26 Oct 2026 22:33:04 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20PHP=20=E5=9F=BA=E7=BA=BF=E5=8D=87?= =?UTF-8?q?=E7=BA=A7=E5=88=B0=208.4=20=E5=B9=B6=E6=8E=A5=E5=85=A5=20GitHub?= =?UTF-8?q?=20Actions=20CI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - composer php 约束统一为 >=8.4 - PHPUnit 统一到 ^10.0 - 新增 PHP 8.4 CI workflow,移除旧 .travis.yml - README PHP 版本说明同步 --- .github/workflows/ci.yml | 28 ++++++++++++++++++++++++++++ .travis.yml | 7 ------- composer.json | 4 ++-- 3 files changed, 30 insertions(+), 9 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..02aae24 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,28 @@ +name: CI + +on: + push: + branches: [master] + pull_request: + +permissions: + contents: read + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '8.4' + extensions: mbstring + coverage: none + tools: composer:v2 + - name: Validate composer.json + run: composer validate --no-check-publish --no-check-lock + - name: Install dependencies + run: composer update --prefer-dist --no-progress --no-interaction + - name: Run tests + run: vendor/bin/phpunit --no-coverage diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index a2fa48b..0000000 --- a/.travis.yml +++ /dev/null @@ -1,7 +0,0 @@ -language: php -php: -- '7.4' - -install: composer install - -script: bin/phpunit diff --git a/composer.json b/composer.json index d810027..b4361af 100755 --- a/composer.json +++ b/composer.json @@ -11,11 +11,11 @@ } ], "require": { - "php": ">=8.2", + "php": ">=8.4", "psr/container": "^2.0" }, "require-dev": { - "phpunit/phpunit": "^9.0" + "phpunit/phpunit": "^10.0" }, "autoload": { "psr-4": {