【发布时间】:2021-08-13 06:39:51
【问题描述】:
我最近开始使用机器人框架进行 api 测试开发。小黄瓜对我来说是全新的。
如何管理 Given 与 When 和 Then 之间的依赖关系?例如: 如果我这么说
Given create account is successful ( which may have the ability to return account no)
When I update my address (this keyword needs the account no set by Given)
Then account should be updated.
现在对于何时成功工作,它应该知道帐户 ID 或交易 ID 或 Given 创建的类似内容。 Given 将如何将数据传递给 When 等等。
这些关键字之间的数据如何保持不变?我没有看到任何示例或 BDD 不适用于此类示例?如果有相关链接,请参考我。
【问题讨论】: