Disable generation of html previews

Adding the option to disable the HTML preview generation was pretty trivial.
However not too hot with writing JS tests. In fact when running the test suite a preview file wasn't being generated in the first place.

I notice you commented out the tests for the previews, is this the reason why?
Thought I'd submit this as is as I'm about to go out and though it'd be worth sharing the WIP.

Any help on writing the tests would be appreciated.