Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SF7] Remove hateoas on Symfony 7 #887

Merged
merged 1 commit into from
May 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 15 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ jobs:
runs-on: ubuntu-latest
continue-on-error: ${{ matrix.experimental }}
name: "PHP ${{ matrix.php }}, Symfony ${{ matrix.symfony }}, Twig ${{ matrix.twig }}, Persistence: ${{ matrix.persistence }}, Collections: ${{ matrix.collections }}"
env:
APP_ENV: ${{ matrix.app_env }}
strategy:
fail-fast: false
matrix:
Expand All @@ -24,13 +26,16 @@ jobs:
persistence: ["^2.0", "^3.0"]
collections: ["^1.8", "^2.0"]
experimental: [false]
app_env: ["test"]
include:
- php: "8.1"
pagerfanta: "^3.7"
symfony: "^5.4"
app_env: "test"
experimental: false
- php: 8.3
symfony: "^7.0"
app_env: "test_without_fosrest"
experimental: true
exclude:
- php: "8.1"
Expand Down Expand Up @@ -92,6 +97,11 @@ jobs:
name: Upgrade winzou-state-machine to dev branch
run: composer require "winzou/state-machine-bundle" "dev-master" --no-update --no-scripts

-
name: Remove hateoas on Symfony 7
if: matrix.symfony == '^7.0'
run: composer remove --dev willdurand/hateoas-bundle --no-update --no-scripts

-
name: Install dependencies
run: |
Expand Down Expand Up @@ -134,7 +144,7 @@ jobs:
if: ${{ true != contains( matrix.php, '8.2' ) }}
run: |
sed -i -e 's/state_machine_component: symfony/state_machine_component: winzou/g' tests/Application/config/packages/test/sylius_resource.yaml
(cd tests/Application && bin/console cache:clear --env=test)
(cd tests/Application && bin/console cache:clear)
vendor/bin/phpspec run --ansi --no-interaction
sed -i -e 's/state_machine_component: winzou/state_machine_component: symfony/g' tests/Application/config/packages/test/sylius_resource.yaml

Expand All @@ -143,7 +153,7 @@ jobs:
name: Run state machine PHPUnit tests with winzou/state-machine package
run: |
sed -i -e 's/state_machine_component: symfony/state_machine_component: winzou/g' tests/Application/config/packages/test/sylius_resource.yaml
(cd tests/Application && bin/console cache:clear --env=test)
(cd tests/Application && bin/console cache:clear)
vendor/bin/phpunit --colors=always
sed -i -e 's/state_machine_component: winzou/state_machine_component: symfony/g' tests/Application/config/packages/test/sylius_resource.yaml

Expand All @@ -152,15 +162,15 @@ jobs:
if: ${{ true != contains( matrix.php, '8.2' ) }}
run: |
sed -i -e 's/state_machine_component: winzou/state_machine_component: symfony/g' tests/Application/config/packages/test/sylius_resource.yaml
(cd tests/Application && bin/console cache:clear --env=test)
(cd tests/Application && bin/console cache:clear)
vendor/bin/phpspec run --ansi --no-interaction
sed -i -e 's/state_machine_component: symfony/state_machine_component: winzou/g' tests/Application/config/packages/test/sylius_resource.yaml

-
name: Run state machine PHPUnit tests with symfony/workflow package
run: |
sed -i -e 's/state_machine_component: winzou/state_machine_component: symfony/g' tests/Application/config/packages/test/sylius_resource.yaml
(cd tests/Application && bin/console cache:clear --env=test)
(cd tests/Application && bin/console cache:clear)
vendor/bin/phpunit --colors=always
sed -i -e 's/state_machine_component: symfony/state_machine_component: winzou/g' tests/Application/config/packages/test/sylius_resource.yaml

Expand All @@ -170,7 +180,7 @@ jobs:
composer remove --dev friendsofsymfony/rest-bundle willdurand/hateoas-bundle jms/serializer-bundle --no-scripts
(cd tests/Application && bin/console cache:clear --env=test_without_fosrest)
(cd tests/Application && bin/console lint:container --env=test_without_fosrest)
composer require friendsofsymfony/rest-bundle willdurand/hateoas-bundle jms/serializer-bundle --no-scripts
composer require --dev friendsofsymfony/rest-bundle willdurand/hateoas-bundle jms/serializer-bundle --no-scripts

-
name: Run lint container without winzou/state-machine-bundle package
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
"conflict": {
"friendsofsymfony/rest-bundle": "<3.0",
"jms/serializer-bundle": "<3.5",
"willdurand/hateoas-bundle": "<2.0"
"willdurand/hateoas-bundle": "<2.0 || ^2.6"
},
"suggest": {
"doctrine/orm": "^2.5",
Expand Down
Loading