jeudi 24 septembre 2015

Can the Karma unit test framework write a file to the file system?

I have a need to be able to write out a text file to the file system from inside a Karma test. I want a test to spit out an HTML file that provides a visual representation of the results of a complex test. Certainly I can read files by specifying test fixtures in karma.conf.js, but as yet I've found no way to output anything to disk. An alternative is to scrape output off the console log and paste it into a file, but that seems awfully clunky.

Any ideas?

Aucun commentaire:

Enregistrer un commentaire