Introduce Sinon.JS and add tests for the generateFile function