-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bug #14155 [BUG] The hostname resolver does not check for the channel…
… status (lruozzi9, jakubtobiasz) This PR was merged into the 1.11 branch. Discussion ---------- | Q | A | |-----------------|--------------------------------------------------------------| | Branch? | 1.11 <!-- see the comment below --> | | Bug fix? | yes | | New feature? | no | | BC breaks? | no | | Deprecations? | yes <!-- don't forget to update the UPGRADE-*.md file --> | | Related tickets | continuation of #13697 | | License | MIT | <!-- - Bug fixes must be submitted against the 1.10 or 1.11 branch(the lowest possible) - Features and deprecations must be submitted against the master branch - Make sure that the correct base branch is set To be sure you are not breaking any Backward Compatibilities, check the documentation: https://docs.sylius.com/en/latest/book/organization/backward-compatibility-promise.html --> What has been done: - Updated behats (In my opinion now they're now a little bit more natural to read) - I rebased the PR on top 1.11 and updated the `UPGRADE-1.11.md` and the `UPGRADE-1.10.md` files We've had a discussion about parametrizing the `HostnameBasedRequestResolver` (what I've done btw 😂) but we decided to drop that idea and keep the original concept. Thank you @lruozzi9 for your PR we could base on :). Commits ------- 28e39e2 [Channel] Do not consider disabled channel on hostname based request resolver 27406cd Adjust behat scenarios 066cf33 Update UPGRADE files 351425d Update deprecation message 55edb2d Remove redundant method 673eb91 Make filtering out scenario available in both ui and api contexts
- Loading branch information
Showing
11 changed files
with
119 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
@channels | ||
Feature: Filtering out disabled channels | ||
In order to avoid mistakes | ||
As a Customer | ||
I want to be able to browse only available shops | ||
|
||
Background: | ||
Given the store operates on a channel named "Fashion" in "USD" currency and with hostname "127.0.0.1" | ||
And the store operates on a channel named "Furniture" in "EUR" currency and with hostname "127.0.0.1" | ||
And there is product "Black T-Shirt" available in "Fashion" channel | ||
And there is product "Old Wardrobe" available in "Furniture" channel | ||
And the channel "Fashion" is disabled | ||
|
||
@ui @api | ||
Scenario: Seeing Furniture shop products | ||
When I check latest products | ||
Then I should see "Old Wardrobe" product | ||
And I should not see "Black T-Shirt" product |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/Sylius/Behat/Resources/config/suites/api/channel/channels.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# This file is part of the Sylius package. | ||
# (c) Paweł Jędrzejewski | ||
|
||
default: | ||
suites: | ||
ui_channels: | ||
contexts: | ||
- sylius.behat.context.hook.doctrine_orm | ||
|
||
- sylius.behat.context.transform.channel | ||
|
||
- sylius.behat.context.setup.channel | ||
- sylius.behat.context.setup.product | ||
|
||
- sylius.behat.context.api.channel | ||
- sylius.behat.context.api.shop.homepage | ||
|
||
filters: | ||
tags: "@channels&&@api" |
19 changes: 19 additions & 0 deletions
19
src/Sylius/Behat/Resources/config/suites/ui/channel/channels.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# This file is part of the Sylius package. | ||
# (c) Paweł Jędrzejewski | ||
|
||
default: | ||
suites: | ||
ui_channels: | ||
contexts: | ||
- sylius.behat.context.hook.doctrine_orm | ||
|
||
- sylius.behat.context.transform.channel | ||
|
||
- sylius.behat.context.setup.channel | ||
- sylius.behat.context.setup.product | ||
|
||
- sylius.behat.context.ui.channel | ||
- sylius.behat.context.ui.shop.homepage | ||
|
||
filters: | ||
tags: "@channels&&@ui" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters