【发布时间】:2020-01-31 04:46:24
【问题描述】:
我在解决 Gatling 中 pebble 模板的点 (.) 表示法以检索变量属性(例如 Map 键值)时遇到问题。
这是我定义的会话属性的示例:
session => session.set("location", Map("text" -> "Alabama"))
我正在尝试将以下 json 模板文件中的 {{ location.text }} 替换为值“Alabama”:
...
"text": "{{ location.text }}",
...
但是,Gatling 似乎无法解析该属性,因此结果为空字符串。
我使用的是 Gatling 3.2.1 版。
任何帮助将不胜感激,谢谢!
【问题讨论】:
标签: gatling scala-gatling pebble