TryKickoff / generator-kickoff

:tennis: Yeoman generator for the Kickoff framework
http://trykickoff.github.io/learn/yeoman.html
MIT License
9 stars 1 forks source link

Including a JS test framework #11

Open ashleynolan opened 8 years ago

ashleynolan commented 8 years ago

On the back of the discussion on the standalone Kickoff build, will look to implement this as part of the generator.

Am planning on doing some work on testing frameworks at JE in December, so should be more informed as to what to include then and will look to use that in Kickoff then.

mrmartineau commented 8 years ago

Cool, cheers mate

munkychop commented 8 years ago

@ashleynolan I’ve been using Mocha with Chai & Sinon for unit tests, which all seem to work pretty well. I used grunt-simple-mocha so that I can run everything through PhantomJS without having to create HTML files. Perhaps a similar setup could work for Kickoff.

Have a look at my Grunt project template for a lightweight example, as it was designed to allow the requiring of Browserify modules from within test spec files. The spec files within test/spec/ are all bundled (via Browserify) into test/bin/test-spec-compiled.js and then mocha is run on this single, compiled file. I also managed to get sourcemaps working with PhantomJS directly in Terminal.

Let me know if you want to go down this route and I'll give you a hand.