giakki/uncss — pull request #14 by ben-eb (2013-12-19 18:48:05+00:00)
Title: Beginnings of a test suite.

This fixes #13; a beginning of a test suite (currently 10 tests) run via Mocha. The tests work by parsing the whole `fixtures` directory into a raw string of CSS and passing that to UnCSS. Then, the tests check in the `unused` directory to make sure what is in there is *not* in the CSS output. Think this is quite a nice way to test the module going forward.

The only problem with this is each test doesn't have a 'clean slate' when it runs, but if it did the test suite would take up more like 16-20 seconds (as it stands, and more when other tests are added). I'd like to know what you think of this approach.