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

Upgrade to Sylius 1.10 and Symfony >5.2 #170

Merged
merged 4 commits into from
Jul 29, 2021
Merged
Show file tree
Hide file tree
Changes from 3 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
10 changes: 5 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,16 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [7.3, 7.4]
php: [7.4, 8.0]
symfony: [^4.4, ^5.2]
sylius: [~1.9.0]
sylius: [1.9.*, 1.10.*]
node: [10.x]
mysql: [5.7, 8.0]

exclude:
- # PHP 7.3 does not support "caching_sha2_password" authentication plugin which is a default one in MySQL 8.0
php: 7.3
mysql: 8.0
-
php: 8.0
sylius: 1.9.*

env:
APP_ENV: test
Expand Down
2 changes: 1 addition & 1 deletion behat.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ default:
extensions:
DMore\ChromeExtension\Behat\ServiceContainer\ChromeExtension: ~

Lakion\Behat\MinkDebugExtension:
FriendsOfBehat\MinkDebugExtension\ServiceContainer\MinkDebugExtension:
directory: etc/build
clean_start: false
screenshot: true
Expand Down
30 changes: 18 additions & 12 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,29 +19,31 @@
}
],
"require": {
"php": "^7.3",
"php": "^7.4 || ^8.0",

"sylius/sylius": "~1.9.0",
"sylius/sylius": "1.9.*",
"friendsofsymfony/jsrouting-bundle": "^2.2",
"friendsofsymfony/oauth-server-bundle": ">2.0.0-alpha.0 ^2.0@dev"
"symfony/flex": "^1.10",
Zales0123 marked this conversation as resolved.
Show resolved Hide resolved
"symfony/asset": "^4.4 || ^5.2",
Zales0123 marked this conversation as resolved.
Show resolved Hide resolved
"friendsofsymfony/oauth-server-bundle": "^1.6 || >2.0.0-alpha.0 ^2.0@dev"
Zales0123 marked this conversation as resolved.
Show resolved Hide resolved
},
"require-dev": {
"behat/behat": "^3.4",
"behat/mink-selenium2-driver": "^1.3",
"behat/behat": "^3.6",
"behat/mink-selenium2-driver": "^1.4",
"dmore/behat-chrome-extension": "^1.3",
"dmore/chrome-mink-driver": "^2.7",
"friends-of-behat/mink": "^1.8",
"friends-of-behat/mink-browserkit-driver": "^1.3",
"friends-of-behat/mink-extension": "^2.3",
"friends-of-behat/mink-extension": "^2.5",
"friends-of-behat/page-object-extension": "^0.3",
"friends-of-behat/suite-settings-extension": "^1.0",
"friends-of-behat/symfony-extension": "^2.0",
"friends-of-behat/variadic-extension": "^1.1",
"lakion/mink-debug-extension": "^1.2.3",
"friends-of-behat/symfony-extension": "^2.1",
"friends-of-behat/variadic-extension": "^1.3",
"friends-of-behat/mink-debug-extension": "^2.0",
"phpspec/phpspec": "^7.0",
"phpstan/phpstan": "0.12.29",
"phpstan/phpstan-webmozart-assert": "0.12.6",
"phpunit/phpunit": "^6.5",
"phpstan/phpstan": "0.12.84",
"phpstan/phpstan-webmozart-assert": "0.12.12",
"phpunit/phpunit": "^9.5",
"se/selenium-server-standalone": "^2.52",
"sylius-labs/coding-standard": "^3.0",
"symfony/debug-bundle": "^4.4 || ^5.2",
Expand Down Expand Up @@ -69,6 +71,10 @@
"extra": {
"branch-alias": {
"dev-master": "1.1-dev"
},
"symfony": {
Zales0123 marked this conversation as resolved.
Show resolved Hide resolved
"require": "^5.2",
"allow-contrib": true
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ protected function getNamespacesOfMigrationsExecutedBefore(): array
{
return [
'Sylius\Bundle\CoreBundle\Migrations',
'Sylius\Bundle\AdminApiBundle\Migrations',
];
}
}
2 changes: 0 additions & 2 deletions tests/Application/config/bundles.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@
Symfony\Bundle\WebServerBundle\WebServerBundle::class => ['all' => true],
Sylius\Bundle\AdminBundle\SyliusAdminBundle::class => ['all' => true],
Sylius\Bundle\ShopBundle\SyliusShopBundle::class => ['all' => true],
FOS\OAuthServerBundle\FOSOAuthServerBundle::class => ['all' => true],
Sylius\Bundle\AdminApiBundle\SyliusAdminApiBundle::class => ['all' => true],
Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true, 'test_cached' => true],
Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true, 'test_cached' => true],
Sylius\AdminOrderCreationPlugin\SyliusAdminOrderCreationPlugin::class => ['all' => true],
Expand Down
1 change: 0 additions & 1 deletion tests/Application/config/packages/_sylius.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ imports:
- { resource: "@SyliusCoreBundle/Resources/config/app/config.yml" }

- { resource: "@SyliusAdminBundle/Resources/config/app/config.yml" }
- { resource: "@SyliusAdminApiBundle/Resources/config/app/config.yml" }

- { resource: "@SyliusShopBundle/Resources/config/app/config.yml" }

Expand Down
16 changes: 0 additions & 16 deletions tests/Application/config/packages/security.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
parameters:
sylius.security.api_regex: "^/api"

security:
providers:
sylius_admin_user_provider:
Expand Down Expand Up @@ -43,17 +40,6 @@ security:
target: sylius_admin_login
anonymous: true

oauth_token:
pattern: "%sylius.security.api_regex%/oauth/v2/token"
security: false

api:
pattern: "%sylius.security.api_regex%/.*"
provider: sylius_admin_user_provider
fos_oauth: true
stateless: true
anonymous: true

new_api_admin_user:
pattern: "%sylius.security.new_api_admin_regex%/.*"
provider: sylius_api_admin_user_provider
Expand Down Expand Up @@ -125,14 +111,12 @@ security:
- { path: "%sylius.security.shop_regex%/_partial", role: ROLE_NO_ACCESS }

- { path: "%sylius.security.admin_regex%/login", role: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: "%sylius.security.api_regex%/login", role: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: "%sylius.security.shop_regex%/login", role: IS_AUTHENTICATED_ANONYMOUSLY }

- { path: "%sylius.security.shop_regex%/register", role: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: "%sylius.security.shop_regex%/verify", role: IS_AUTHENTICATED_ANONYMOUSLY }

- { path: "%sylius.security.admin_regex%", role: ROLE_ADMINISTRATION_ACCESS }
- { path: "%sylius.security.api_regex%/.*", role: ROLE_API_ACCESS }
- { path: "%sylius.security.shop_regex%/account", role: ROLE_USER }

- { path: "%sylius.security.new_api_admin_regex%/.*", role: ROLE_API_ACCESS }
Expand Down
9 changes: 0 additions & 9 deletions tests/Application/config/packages/security_checker.yaml

This file was deleted.

3 changes: 0 additions & 3 deletions tests/Application/config/routes/sylius_admin_api.yaml

This file was deleted.