html tool

2020年4月28日星期二

robotframwork tuple 引用

官方標準解答是使用Convert To List
t.robot.txt                                                      
 17     BuiltIn.log     ${tu}
 18     BuiltIn.log     ${tl}
 19     ${c_tu}=     Convert To List    ${tu}
 20     BuiltIn.log     ${c_tu}
 21     BuiltIn.log     ${c_tu}[0]
 22 #    BuiltIn.log    ${ngtdp_server}
 23 #    BuiltIn.log    ${dic_web}
定義 t.py
  1 tu = ('fail', {'ip': 'pass'})
  2 tl = ['fail', {'ip': 'pass'}]


没有评论:

发表评论