The file API is a bit simple. It might improve usability to provide Sinks that the user can write outputs to, e.g.
- StringSink#write(String text)
- SerializableSink#write(Serializable Object)
- XMLSink#write(DOM tree)
These need to have a corresponding read method to be used for approval/comparison.
The output should still be represented in a textual format in order to present a diff to the user.