Hi,
when using a Fluent Form Prefill, the service returns a 'Document', so you can use this pattern in unit tests to examine the prefill formXml:
Document result = (Document) new ServiceInvoker(svcDef)
.setLogger(logger)
.invoke(params)
assert result != null
Path path = new Path(result)
assert "9999" == path.val("//Customer/Address/PostCode")
However, when using a Fluent Function, with trigger = Open, that returns a FuncResult, not the actual funcResult.appDoc or similar.
How can I unit test a Fluent Function (Open) so that I can verify the prefill data?
How do I get access to the 'appDoc'?
I have tried a few options, like MockTxn, MockFuncParam, MockDocument, Document with Test XML Data, but all results return the seed formXml with no data, or other results that aren't correct.
Thanks
Mark