output: first implementation of output configuration

Add a feature whereby the output from mocha can be sent to a file instead
of to console.

Only implemented for the xunit reporter (for now).