我正在尝试使用空手道和 Spring JDBC 运行一些基本的数据库测试(如 Demo Project 中的 DBUtils 类中所述)。
这是我正在做的事情:
Background:
# Read url/username/pwd and provide it to the class
* def config = read('env_file.json')
* def DbUtils = Java.type('DbConnection')
* def db = new DbUtils(config)
Scenario: Validate the modd_ts is present in lob table
* def createdTs = db.readRows('SELECT crtd_ts FROM tableA ')
* print createdTs
这是它返回的内容:
com.intuit.karate - [print] [{"crtd_ts":{"nanos":0}},{"crtd_ts":{"nanos":0}}
不知道为什么它应该将时间戳返回为 "nanos":0 ,这对我来说似乎是一个错误。请确认,我将在 github 中打开一个。