Give an argument to a Fitnesse output method?
My Fitnesse test does some underlying stuff and populates a Map with the results. The map keys can vary drama开发者_如何学JAVAtically depending on the test, so I'd like to something like the following:
|parseFile |getValue("RecordID")|getValue("StatusCode")| ...etc... |
|foo.txt | MyId | 93 | |
I could create a getRecordID() method in the Java code, but the keys tend to vary widely (dozens of formats, each with it's own key names...supporting arbitrary customer formats). Can this be done in Fitnesse? I can't figure out how.
Take a look at DoFixture where you can do something like this:
|myDoFixture|
|parseFile|foo.txt|
|verifyMap|
|key|value|
|RecordId|MyId|
|StatusCode|93|
...
精彩评论