0

したがって、この機能の他のシナリオでこれらの手順を繰り返す必要があるシナリオの概要があり、機能ファイルで手順を手動で複製したくありません。

私は試しBackgroundましたが、まだ成功していません。

シナリオは次のとおりです。

Scenario Outline: Adding an item to shopping cart
Given I am on home page
When i browse to category
And i click on the product
And I add <x> product to the bag
Then I should see the <x> in my mini-bag
And I click on the basket to verify if I have <x> items
Examples:
|x|
|1|

2 番目のシナリオ:

Scenario Outline: ...
[I want the steps in the scenario above until 
 "Then I should see the <x> in my mini-bag" to be executed here.]
Given I am on the basket
When I edit the quantity to <y>
And I click the apply button
Then I should the quantity <y>
Examples:
|x|
|1|

execute_stepsすべてのステップで重複しているすべてのシナリオに使用したくありません。

4

0 に答える 0