From 4b493836e34e15e7a0ed018a85e430554cff5a24 Mon Sep 17 00:00:00 2001 From: Martin Heise Date: Mon, 29 Jul 2024 15:46:19 +0200 Subject: [PATCH] Fix CI --- .github/workflows/ci.yml | 16 ++++++++++++++++ composer.json | 7 +++++-- tests/Extensions/ImageExtensionTest.php | 3 ++- 3 files changed, 23 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..85a5a1b --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,16 @@ +name: CI + +on: + push: + pull_request: + workflow_dispatch: + +permissions: {} + +jobs: + ci: + name: CI + uses: silverstripe/gha-ci/.github/workflows/ci.yml@v1 + permissions: + pull-requests: read + contents: write diff --git a/composer.json b/composer.json index dab4c1f..3da4e03 100644 --- a/composer.json +++ b/composer.json @@ -21,12 +21,15 @@ "mhe/imagetools": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^9.5" + "phpunit/phpunit": "^9.5", + "squizlabs/php_codesniffer": "^3.7" }, "autoload": { "psr-4": { "Mhe\\SmartImages\\": "src/", "Mhe\\SmartImages\\Tests\\": "tests/" } - } + }, + "minimum-stability": "dev", + "prefer-stable": true } diff --git a/tests/Extensions/ImageExtensionTest.php b/tests/Extensions/ImageExtensionTest.php index 5e99e35..23ee389 100644 --- a/tests/Extensions/ImageExtensionTest.php +++ b/tests/Extensions/ImageExtensionTest.php @@ -2,7 +2,8 @@ namespace Mhe\SmartImages\Tests\Extensions; -use DOMDocument, DOMXPath; +use DOMDocument; +use DOMXPath; use Mhe\SmartImages\Extensions\ImageExtension; use Page; use SilverStripe\Assets\Dev\TestAssetStore;