我可以在方案大纲中运行示例n次吗?

时间:2019-01-28 09:49:10

标签: karate

我想运行示例n次,ngetHotelid的数据长度。

Feature: match rates from ds api to pricing api.

 Background:

 * url ''

 Scenario Outline: Calling production assert feature file.

 * def DbNew = Java.type('DbNew')
 * def dq = new DbNew()
 * def activeHotels = <ds_hotel_id>

 * def hotel_id = call read('StringConverter.js') { activeHotels:'#(activeHotels)'}

 * print hotel_id

Examples:
|dq.getHotelid()|

1 个答案:

答案 0 :(得分:1)

这看起来像Karate - Not able to run dynamic scenario outline in a loop

您的示例应如下所示,

Examples:
 |dq.getHotelid()|

请阅读此文档:Karate dynamic scenario