Robotframework 模板关键字can';t处理RF 3.2.1中的线路中断
如果在Robot Framework 3.1.2中工作正常,但在3.2.1中,我会收到错误消息: 设置“模板”只接受一个值,得到2 我看不到文档中有任何解释这一点的更新。有什么想法吗Robotframework 模板关键字can';t处理RF 3.2.1中的线路中断,robotframework,Robotframework,如果在Robot Framework 3.1.2中工作正常,但在3.2.1中,我会收到错误消息: 设置“模板”只接受一个值,得到2 我看不到文档中有任何解释这一点的更新。有什么想法吗 *** Test Cases *** Test Case [Template] The result of ${calculation} ... should be ${expected} 1 + 1 2 2 + 2 4 *** Keyword
*** Test Cases ***
Test Case
[Template] The result of ${calculation}
... should be ${expected}
1 + 1 2
2 + 2 4
*** Keywords ***
The result of ${calculation} should be ${expected}
${result} = Evaluate ${calculation}
Should Be Equal As Integers ${result} ${expected}
…
标记参数边界。您所做的与此完全相同:
[Template] The result of ${calculation} should be ${expected}
就像错误所说的那样,[Template]
设置只接受一个参数,但传递两个参数。不能在多行上定义关键字
看来旧的(3.2之前的)解析器可能有点松懈,允许您在多行上拆分模板关键字。新的解析器不允许这样做。这太糟糕了。这当然是我问题的简化。我的关键字将更难理解,如果我必须保持在120个字符以下(这是项目中的最大行长度)。