嵌套示例:在Cucumber要素文件中
有可能出现以下情况吗?我正在使用葫芦android进行测试 我有3种类型的用户嵌套示例:在Cucumber要素文件中,cucumber,gherkin,calabash-android,Cucumber,Gherkin,Calabash Android,有可能出现以下情况吗?我正在使用葫芦android进行测试 我有3种类型的用户 我想登录3个元素中的每一个,并确保屏幕上有9个元素中的每一个 我可以嵌套3个用户类型,然后让每个用户类型查找9个元素中的每一个吗 Feature: Overview screen on Mobile App In order to access all the features of the Mobile App As a user of the Mobile App I want to be able
我想登录3个元素中的每一个,并确保屏幕上有9个元素中的每一个 我可以嵌套3个用户类型,然后让每个用户类型查找9个元素中的每一个吗
Feature: Overview screen on Mobile App
In order to access all the features of the Mobile App
As a user of the Mobile App
I want to be able to access the features through the Overview Screen
@high
Scenario Outline: Overview Screen Appearance
Given I login to an <type> account
Examples:
| type |
| secure |
| user |
| admin |
Then I should see the <element>
Examples:
| element |
| Overview Header |
| Status Icon |
| Status Text |
| Status Time |
| Current Temp Icon |
| Navigation Overview Text |
| Navigation Overview Icon |
| Navigation Activity Text |
| Navigation Activity Icon |
功能:移动应用程序上的概览屏幕
以访问移动应用程序的所有功能
作为移动应用程序的用户
我希望能够通过概览屏幕访问这些功能
@高
场景大纲:概览屏幕外观
如果我登录到一个帐户
示例:
|类型|
|稳妥|
|使用者|
|管理员|
那我就去看电影了
示例:
|元素|
|概述标题|
|状态图标|
|状态文本|
|状态时间|
|当前温度图标|
|导航概述文本|
|导航概览图标|
|导航活动文本|
|导航活动图标|
谢谢,这听起来更像是使用数据表的任务。然后,实现该步骤的代码将检查datatable参数的每个元素是否存在于页面上
Scenario Outline: Overview Screen Appearance
Given I login to an <type> account
Then I should see the following elements:
| element |
| Overview Header |
| Status Icon |
| Status Text |
| Status Time |
| Current Temp Icon |
| Navigation Overview Text |
| Navigation Overview Icon |
| Navigation Activity Text |
| Navigation Activity Icon |
Examples:
| type |
| secure |
| user |
| admin |
场景大纲:概览屏幕外观
如果我登录到一个帐户
然后我将看到以下元素:
|元素|
|概述标题|
|状态图标|
|状态文本|
|状态时间|
|当前温度图标|
|导航概述文本|
|导航概览图标|
|导航活动文本|
|导航活动图标|
示例:
|类型|
|稳妥|
|使用者|
|管理员|
< /代码> 您也可以考虑使用FasyYMy.< /P>
如果您有复杂的数据模型,您可以简单地以工厂的形式将其抽象出来,而不是制作复杂的静态特征文件。非常好。我会试一试的。