From b206d148ba390d1cdd2d21becf612e4f45e8fde0 Mon Sep 17 00:00:00 2001 From: Grzegorz Sadowski Date: Wed, 25 Oct 2017 23:07:52 +0200 Subject: [PATCH] [Behat] Add scenarios for deleting multiple resources --- .../deleting_multiple_zones.feature | 19 ++++++++++++++++ .../deleting_multiple_channels.feature | 21 ++++++++++++++++++ .../deleting_multiple_exchange_rates.feature | 22 +++++++++++++++++++ .../deleting_multiple_payment_methods.feature | 21 ++++++++++++++++++ ...multiple_product_association_types.feature | 21 ++++++++++++++++++ ...leting_multiple_product_attributes.feature | 21 ++++++++++++++++++ .../deleting_multiple_product_options.feature | 21 ++++++++++++++++++ .../deleting_multiple_product_reviews.feature | 22 +++++++++++++++++++ ...deleting_multiple_product_variants.feature | 20 +++++++++++++++++ .../deleting_multiple_products.feature | 19 ++++++++++++++++ .../deleting_multiple_coupons.feature | 20 +++++++++++++++++ .../deleting_multiple_promotions.feature | 21 ++++++++++++++++++ ...eting_multiple_shipping_categories.feature | 20 +++++++++++++++++ ...deleting_multiple_shipping_methods.feature | 20 +++++++++++++++++ .../deleting_multiple_tax_categories.feature | 19 ++++++++++++++++ .../deleting_multiple_tax_rates.feature | 21 ++++++++++++++++++ .../deleting_multiple_administrators.feature | 21 ++++++++++++++++++ .../deleting_multiple_customer_groups.feature | 20 +++++++++++++++++ 18 files changed, 369 insertions(+) create mode 100644 features/addressing/managing_zones/deleting_multiple_zones.feature create mode 100644 features/channel/managing_channels/deleting_multiple_channels.feature create mode 100644 features/currency/managing_exchange_rates/deleting_multiple_exchange_rates.feature create mode 100644 features/payment/managing_payment_methods/deleting_multiple_payment_methods.feature create mode 100644 features/product/managing_product_association_types/deleting_multiple_product_association_types.feature create mode 100644 features/product/managing_product_attributes/deleting_multiple_product_attributes.feature create mode 100644 features/product/managing_product_options/deleting_multiple_product_options.feature create mode 100644 features/product/managing_product_reviews/deleting_multiple_product_reviews.feature create mode 100644 features/product/managing_product_variants/deleting_multiple_product_variants.feature create mode 100644 features/product/managing_products/deleting_multiple_products.feature create mode 100644 features/promotion/managing_coupons/deleting_multiple_coupons.feature create mode 100644 features/promotion/managing_promotions/deleting_multiple_promotions.feature create mode 100644 features/shipping/managing_shipping_categories/deleting_multiple_shipping_categories.feature create mode 100644 features/shipping/managing_shipping_methods/deleting_multiple_shipping_methods.feature create mode 100644 features/taxation/managing_tax_categories/deleting_multiple_tax_categories.feature create mode 100644 features/taxation/managing_tax_rates/deleting_multiple_tax_rates.feature create mode 100644 features/user/managing_administrators/deleting_multiple_administrators.feature create mode 100644 features/user/managing_customer_groups/deleting_multiple_customer_groups.feature diff --git a/features/addressing/managing_zones/deleting_multiple_zones.feature b/features/addressing/managing_zones/deleting_multiple_zones.feature new file mode 100644 index 00000000000..4a5730fbd35 --- /dev/null +++ b/features/addressing/managing_zones/deleting_multiple_zones.feature @@ -0,0 +1,19 @@ +@managing_zones +Feature: Deleting multiple zones + In order to remove test, obsolete or incorrect zones + As an Administrator + I want to be able to delete multiple zones + + Background: + Given the store has zones "North America", "South America" and "Europe" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple zones + When I browse zones + And I check the "North America" zone + And I check also the "South America" zone + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single zone in the list + And I should see the zone "Europe" in the list diff --git a/features/channel/managing_channels/deleting_multiple_channels.feature b/features/channel/managing_channels/deleting_multiple_channels.feature new file mode 100644 index 00000000000..204e888d5f7 --- /dev/null +++ b/features/channel/managing_channels/deleting_multiple_channels.feature @@ -0,0 +1,21 @@ +@managing_channels +Feature: Deleting multiple channels + In order to remove test, obsolete or incorrect channels + As an Administrator + I want to be able to delete multiple channels + + Background: + Given the store operates on a channel named "US Store" + And the store operates on another channel named "PL Store" + And the store operates on another channel named "DE Store" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple channels + When I browse channels + And I check the "PL Store" channel + And I check also the "DE Store" channel + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single channel in the list + And I should see the channel "US Store" in the list diff --git a/features/currency/managing_exchange_rates/deleting_multiple_exchange_rates.feature b/features/currency/managing_exchange_rates/deleting_multiple_exchange_rates.feature new file mode 100644 index 00000000000..d9ba0bff4d1 --- /dev/null +++ b/features/currency/managing_exchange_rates/deleting_multiple_exchange_rates.feature @@ -0,0 +1,22 @@ +@managing_exchange_rates +Feature: Deleting multiple exchange rates + In order to remove obsolete exchange rates + As an Administrator + I want to be able to delete multiple exchange rates + + Background: + Given the store has currency "Euro", "British Pound" and "Polish Zloty" + And the exchange rate of "Euro" to "British Pound" is 0.84 + And the exchange rate of "British Pound" to "Polish Zloty" is 5.31 + And the exchange rate of "Polish Zloty" to "Euro" is 0.22 + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple exchange rates + When I browse exchange rates + And I check the exchange rate between "Euro" and "British Pound" + And I check the exchange rate between "British Pound" and "Polish Zloty" + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single exchange rate in the list + And I should see the exchange rate between "Polish Zloty" and "Euro" in the list diff --git a/features/payment/managing_payment_methods/deleting_multiple_payment_methods.feature b/features/payment/managing_payment_methods/deleting_multiple_payment_methods.feature new file mode 100644 index 00000000000..2b0e4826a2d --- /dev/null +++ b/features/payment/managing_payment_methods/deleting_multiple_payment_methods.feature @@ -0,0 +1,21 @@ +@managing_payment_methods +Feature: Deleting multiple payment methods + In order to remove test, obsolete or incorrect payment methods + As an Administrator + I want to be able to delete multiple payment methods + + Background: + Given the store has a payment method "Offline" with a code "offline" + And the store has also a payment method "Bank transfer" with a code "transfer" + And the store has also a payment method "PayPal Express Checkout" with a code "paypal" and Paypal Express Checkout gateway + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple payment methods + When I browse payment methods + And I check the "Offline" payment method + And I check also the "Bank transfer" payment method + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single payment method in the list + And I should see the payment method "PayPal Express Checkout" in the list diff --git a/features/product/managing_product_association_types/deleting_multiple_product_association_types.feature b/features/product/managing_product_association_types/deleting_multiple_product_association_types.feature new file mode 100644 index 00000000000..cbf69cacf91 --- /dev/null +++ b/features/product/managing_product_association_types/deleting_multiple_product_association_types.feature @@ -0,0 +1,21 @@ +@managing_product_association_types +Feature: Deleting multiple product association types + In order to remove test, obsolete or incorrect product association types + As an Administrator + I want to be able to delete multiple product association types + + Background: + Given the store has a product association type "Cross sell" + And the store has also a product association type "Up sell" + And the store has also a product association type "Accessories" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple product association types + When I browse product association types + And I check the "Cross sell" product association type + And I check also the "Up sell" product association type + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product association type in the list + And I should see the product association type "Accessories" in the list diff --git a/features/product/managing_product_attributes/deleting_multiple_product_attributes.feature b/features/product/managing_product_attributes/deleting_multiple_product_attributes.feature new file mode 100644 index 00000000000..12234abc1e8 --- /dev/null +++ b/features/product/managing_product_attributes/deleting_multiple_product_attributes.feature @@ -0,0 +1,21 @@ +@managing_product_attributes +Feature: Deleting multiple product attributes + In order to remove test, obsolete or incorrect product attributes + As an Administrator + I want to be able to delete multiple product attributes + + Background: + Given the store has a text product attribute "Publisher" + And the store has a textarea product attribute "Description" + And the store has a integer product attribute "Pages" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple product attributes + When I browse product attributes + And I check the "Publisher" product attribute + And I check also the "Description" product attribute + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product attribute in the list + And I should see the product attribute "Pages" in the list diff --git a/features/product/managing_product_options/deleting_multiple_product_options.feature b/features/product/managing_product_options/deleting_multiple_product_options.feature new file mode 100644 index 00000000000..aabfa1993fd --- /dev/null +++ b/features/product/managing_product_options/deleting_multiple_product_options.feature @@ -0,0 +1,21 @@ +@managing_product_attributes +Feature: Deleting multiple product options + In order to remove test, obsolete or incorrect product options + As an Administrator + I want to be able to delete multiple product options + + Background: + Given the store has a product option "T-Shirt size" + And the store has also a product option "T-Shirt color" + And the store has also a product option "T-Shirt brand" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple product options + When I browse product options + And I check the "T-Shirt size" product option + And I check also the "T-Shirt color" product option + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product option in the list + And I should see the product option "T-Shirt brand" in the list diff --git a/features/product/managing_product_reviews/deleting_multiple_product_reviews.feature b/features/product/managing_product_reviews/deleting_multiple_product_reviews.feature new file mode 100644 index 00000000000..2f4f8070b84 --- /dev/null +++ b/features/product/managing_product_reviews/deleting_multiple_product_reviews.feature @@ -0,0 +1,22 @@ +@managing_product_reviews +Feature: Deleting multiple product reviews + In order to remove test, obsolete or incorrect product reviews + As an Administrator + I want to be able to delete multiple product reviews + + Background: + Given the store has a product "Audi RS7 model" + And this product has a review titled "Awesome" and rated 5 with a comment "Nice product" added by customer "batman@dc.com" + And this product has also a review titled "Bad" and rated 1 with a comment "Really bad" added by customer "theflash@dc.com" + And this product has also a review titled "Cool" and rated 4 with a comment "Quite cool" added by customer "aquaman@dc.com" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple product reviews + When I browse product reviews + And I check the "Awesome" product review + And I check also the "Bad" product review + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product review in the list + And I should see the product review "Cool" in the list diff --git a/features/product/managing_product_variants/deleting_multiple_product_variants.feature b/features/product/managing_product_variants/deleting_multiple_product_variants.feature new file mode 100644 index 00000000000..05497f6bf33 --- /dev/null +++ b/features/product/managing_product_variants/deleting_multiple_product_variants.feature @@ -0,0 +1,20 @@ +@managing_product_variants +Feature: Deleting multiple product variants + In order to remove test, obsolete or incorrect product variants + As an Administrator + I want to be able to delete multiple product variants from the product catalog + + Background: + Given the store has a product "PHP Mug" + And this product has "Small PHP Mug", "Medium PHP Mug" and "Big PHP Mug" variants + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple product variants + When I browse variants of this product + And I check the "Small PHP Mug" product variant + And I check also the "Medium PHP Mug" product variant + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product variant in the list + And I should see the product variant "Big PHP Mug" in the list diff --git a/features/product/managing_products/deleting_multiple_products.feature b/features/product/managing_products/deleting_multiple_products.feature new file mode 100644 index 00000000000..572d79b08e1 --- /dev/null +++ b/features/product/managing_products/deleting_multiple_products.feature @@ -0,0 +1,19 @@ +@managing_products +Feature: Deleting multiple products + In order to remove test, obsolete or incorrect products + As an Administrator + I want to be able to delete multiple products from the product catalog + + Background: + Given the store has "Audi RS5 model", "Audi RS6 model" and "Audi RS7 model" products + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple products + When I browse products + And I check the "Audi RS5 model" product + And I check also the "Audi RS6 model" product + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single product in the list + And I should see the product "Audi RS7 model" in the list diff --git a/features/promotion/managing_coupons/deleting_multiple_coupons.feature b/features/promotion/managing_coupons/deleting_multiple_coupons.feature new file mode 100644 index 00000000000..64ada2092da --- /dev/null +++ b/features/promotion/managing_coupons/deleting_multiple_coupons.feature @@ -0,0 +1,20 @@ +@managing_promotion_coupons +Feature: Deleting multiple coupons + In order to remove test, obsolete or incorrect coupons + As an Administrator + I want to be able to delete multiple coupons from the registry + + Background: + Given there is a promotion "Christmas sale" + And this promotion has "SANTA1", "SANTA2" and "SANTA3" coupons + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple coupons + When I browse coupons of this promotion + And I check the "SANTA1" coupon + And I check also the "SANTA2" coupon + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single coupon in the list + And I should see the coupon "SANTA3" in the list diff --git a/features/promotion/managing_promotions/deleting_multiple_promotions.feature b/features/promotion/managing_promotions/deleting_multiple_promotions.feature new file mode 100644 index 00000000000..fb86b560508 --- /dev/null +++ b/features/promotion/managing_promotions/deleting_multiple_promotions.feature @@ -0,0 +1,21 @@ +@managing_promotions +Feature: Deleting multiple promotions + In order to remove test, obsolete or incorrect promotions + As an Administrator + I want to be able to delete multiple promotions from the registry + + Background: + Given there is a promotion "Christmas sale" + And there is also a promotion "New Year sale" + And there is also a promotion "Easter sale" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple promotions + When I browse promotions + And I check the "Christmas sale" promotion + And I check also the "New Year sale" promotion + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single promotion in the list + And I should see the promotion "Easter sale" in the list diff --git a/features/shipping/managing_shipping_categories/deleting_multiple_shipping_categories.feature b/features/shipping/managing_shipping_categories/deleting_multiple_shipping_categories.feature new file mode 100644 index 00000000000..ed345f93f05 --- /dev/null +++ b/features/shipping/managing_shipping_categories/deleting_multiple_shipping_categories.feature @@ -0,0 +1,20 @@ +@managing_shipping_categories +Feature: Deleting multiple shipping categories + In order to remove test, obsolete or incorrect shipping categories + As an Administrator + I want to be able to delete multiple shipping categories + + Background: + Given the store has "Standard" shipping category + And the store has "Big" and "Small" shipping category + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple shipping categories + When I browse shipping categories + And I check the "Big" shipping category + And I check also the "Small" shipping category + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single shipping category in the list + And I should see the shipping category "Standard" in the list diff --git a/features/shipping/managing_shipping_methods/deleting_multiple_shipping_methods.feature b/features/shipping/managing_shipping_methods/deleting_multiple_shipping_methods.feature new file mode 100644 index 00000000000..d22dbab31a2 --- /dev/null +++ b/features/shipping/managing_shipping_methods/deleting_multiple_shipping_methods.feature @@ -0,0 +1,20 @@ +@managing_shipping_methods +Feature: Deleting multiple shipping methods + In order to remove test, obsolete or incorrect shipping methods + As an Administrator + I want to be able to delete multiple shipping methods + + Background: + Given the store operates on a single channel in "United States" + And the store allows shipping with "UPS", "FedEx" and "DHL" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple shipping methods + When I browse channels + And I check the "UPS" shipping method + And I check also the "FedEx" shipping method + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single shipping method in the list + And I should see the shipping method "DHL" in the list diff --git a/features/taxation/managing_tax_categories/deleting_multiple_tax_categories.feature b/features/taxation/managing_tax_categories/deleting_multiple_tax_categories.feature new file mode 100644 index 00000000000..05df1fa48e4 --- /dev/null +++ b/features/taxation/managing_tax_categories/deleting_multiple_tax_categories.feature @@ -0,0 +1,19 @@ +@managing_tax_categories +Feature: Deleting multiple tax categories + In order to remove test, obsolete or incorrect tax categories + As an Administrator + I want to be able to delete multiple tax categories + + Background: + Given the store has tax categories "Alcohol", "Food" and "Books" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple tax categories + When I browse tax categories + And I check the "Alcohol" tax category + And I check also the "Food" tax category + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single tax category in the list + And I should see the tax category "Books" in the list diff --git a/features/taxation/managing_tax_rates/deleting_multiple_tax_rates.feature b/features/taxation/managing_tax_rates/deleting_multiple_tax_rates.feature new file mode 100644 index 00000000000..e7866f3cd94 --- /dev/null +++ b/features/taxation/managing_tax_rates/deleting_multiple_tax_rates.feature @@ -0,0 +1,21 @@ +@managing_tax_categories +Feature: Deleting multiple tax rates + In order to remove test, obsolete or incorrect tax rates + As an Administrator + I want to be able to delete multiple tax rates + + Background: + Given the store has "VAT" tax rate of 23% for "Alcohol" for the rest of the world + And the store has "Low VAT" tax rate of 8% for "Books" for the rest of the world + And the store has "High VAT" tax rate of 40% for "Food" for the rest of the world + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple tax rates + When I browse tax rates + And I check the "VAT" tax rate + And I check also the "Low VAT" tax rate + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single tax rate in the list + And I should see the tax rate "High VAT" in the list diff --git a/features/user/managing_administrators/deleting_multiple_administrators.feature b/features/user/managing_administrators/deleting_multiple_administrators.feature new file mode 100644 index 00000000000..cc192b5cac5 --- /dev/null +++ b/features/user/managing_administrators/deleting_multiple_administrators.feature @@ -0,0 +1,21 @@ +@managing_administrators +Feature: Deleting multiple administrators + In order to get rid of deprecated administrators + As an Administrator + I want to be able to delete multiple administrator accounts + + Background: + Given there is an administrator "banana@example.com" + And there is also an administrator "orange@example.com" + And there is also an administrator "watermelon@example.com" + And I am logged in as "watermelon@example.com" administrator + + @ui @javascript + Scenario: Deleting multiple administrators + Given I browse administrators + And I check the "banana@example.com" administrator + And I check also the "orange@example.com" administrator + And I delete them + Then I should be notified that they have been successfully deleted + And I should see a single administrator in the list + And I should see the administrator "watermelon@example.com" in the list diff --git a/features/user/managing_customer_groups/deleting_multiple_customer_groups.feature b/features/user/managing_customer_groups/deleting_multiple_customer_groups.feature new file mode 100644 index 00000000000..06c45955053 --- /dev/null +++ b/features/user/managing_customer_groups/deleting_multiple_customer_groups.feature @@ -0,0 +1,20 @@ +@managing_customer_groups +Feature: Deleting multiple customer groups + In order to remove test, obsolete or incorrect customer groups + As an Administrator + I want to be able to delete multiple customer groups + + Background: + Given the store has customer groups "Retail", "Wholesale", "General" and "VIP" + And I am logged in as an administrator + + @ui @javascript + Scenario: Deleting multiple customer groups + When I browse customer groups + And I check the "Retail" customer group + And I check also the "Wholesale" customer group + And I delete them + Then I should be notified that they have been successfully deleted + And I should see 2 customer groups in the list + And I should see the customer group "General" in the list + And I should see also the customer group "VIP" in the list