From 0a73f1a3ac77de943d6b8cd10cef5dcbdafca37a Mon Sep 17 00:00:00 2001 From: kevins Date: Tue, 26 Oct 2021 15:29:46 +0200 Subject: [PATCH 1/2] Added multiple PHP versions to the build process. --- .github/workflows/build.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5540f78..3a8341c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,12 +4,16 @@ on: [pull_request, push] jobs: build: + name: Build - PHP ${{ matrix.php-versions }} runs-on: ubuntu-latest + strategy: + matrix: + php-versions: [ '7.2', '7.3', '7.4', '8.0' ] steps: - name: Setup PHP, with composer and extensions uses: shivammathur/setup-php@v1 with: - php-version: 7.2 + php-version: ${{ matrix.php-versions }} - uses: actions/checkout@v1 From 32eecbbee41fdf38e646f02248a54b21540bbc1c Mon Sep 17 00:00:00 2001 From: kevins Date: Tue, 26 Oct 2021 15:30:10 +0200 Subject: [PATCH 2/2] Fixed some dependency versions. And updated the Status to work with the new Enum version. --- composer.json | 6 +++--- src/Enum/Transition/Status.php | 5 +++++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/composer.json b/composer.json index f74a0ba..40f1c0a 100644 --- a/composer.json +++ b/composer.json @@ -27,9 +27,9 @@ }, "require": { "php": "^7.2 || ^8.0", - "aeviiq/collection": "^3.3", - "aeviiq/storage-manager": "^5.0", - "aeviiq/enum": "^2.0", + "aeviiq/collection": "^3.2", + "aeviiq/storage-manager": "^3.0 || ^4.0 || ^5.0", + "aeviiq/enum": "^3.0", "symfony/form": "^4.3 || ^5.0", "symfony/http-foundation": "^4.3 || ^5.0", "symfony/event-dispatcher-contracts": "^1.0 || ^2.0" diff --git a/src/Enum/Transition/Status.php b/src/Enum/Transition/Status.php index 11832eb..af7cfce 100644 --- a/src/Enum/Transition/Status.php +++ b/src/Enum/Transition/Status.php @@ -97,4 +97,9 @@ public function isUnhandledForm(): bool { return $this->contains(new self(self::UNHANDLED_FORM)); } + + private function isFlagSet(int $flags, int $flag): bool + { + return ($flag & $flags) === $flag; + } }