情景与情景大纲的区别
Difference between scenario and scenaio out line
我创建了以下功能并在另一个功能文件中调用它
@忽略
功能:可重复使用的功能来创建单个订单
场景大纲:创建多个用户并验证他们的id、姓名和年龄
给定url 'https://arid-stage.****/sun-api//user/****'
并请求 { locale:'',offerId:'',operationType:'',paidTermDuration:'',paidTermDurationUnit:'',paymentCategory:'',storeOrderId:'',userId:'' }
当方法 post
然后状态200
例子:
|语言环境 |优惠编号 |操作类型| paidTermDuration |paidTermDurationUnit |付款类别 |storeOrderId|userId |
| en_us | 7777777 |创建 | 30 |月份 | VENDOR_PAYMENT |本地日期 | 42DC198E5ABCE1430A494128 |
在其他功能中,我正在调用功能 -> * def result = call read('redeem-create.feature')
问题:
这只会在文本 场景大纲 并且我删除并更新为场景时执行,这不会被执行。
何时使用场景大纲和场景
任何建议/想法
为什么不阅读文档:https://github.com/intuit/karate#data-driven-tests
还要看这个例子进行比较:examples.feature
我创建了以下功能并在另一个功能文件中调用它
@忽略 功能:可重复使用的功能来创建单个订单
场景大纲:创建多个用户并验证他们的id、姓名和年龄
给定url 'https://arid-stage.****/sun-api//user/****'
并请求 { locale:'',offerId:'',operationType:'',paidTermDuration:'',paidTermDurationUnit:'',paymentCategory:'',storeOrderId:'',userId:'' } 当方法 post 然后状态200
例子: |语言环境 |优惠编号 |操作类型| paidTermDuration |paidTermDurationUnit |付款类别 |storeOrderId|userId | | en_us | 7777777 |创建 | 30 |月份 | VENDOR_PAYMENT |本地日期 | 42DC198E5ABCE1430A494128 |
在其他功能中,我正在调用功能 -> * def result = call read('redeem-create.feature')
问题: 这只会在文本 场景大纲 并且我删除并更新为场景时执行,这不会被执行。
何时使用场景大纲和场景
任何建议/想法
为什么不阅读文档:https://github.com/intuit/karate#data-driven-tests
还要看这个例子进行比较:examples.feature