upstage/less.js — pull request #1 by SomMeri (2013-08-07 15:09:05+00:00)
Title: Refactoring browser unit tests into grunt-contrib-jasmine

Use following command to run browser tests:
* `grunt browserTest`

It starts web server and then runs all 10 browser browser test suites: main, browser, errors, legacy, noJsErrors, relativeUrls, rootpath, rootpathRelative, production, modifyVars. Each suite creates `test/browser/test-runner-.html` file and opens it in phantomjs. Test runner is not deleted after tests. It can be run again in real browser if someone wants to.

If you want to run only one test suite, you have to do following:

* `grunt connect:server:keepalive` - starts web server,
* `grunt jasmine:` - creates test runner and runs it.

Important changes:
* Server root changed. It used to run in less.js/test directory and now it runs less.js directory.
* Less.js used to be run in asynchronous mode, now it is synchronous.

Using less.js from master branch gives following results:
* test-runner-main - 9 failures,
* test-runner-browser - 2 failures,
* test-runner-errors - 2 failures.

Failures seems to be caused by new features and everything else passes. It behaves the same way in chrome and phantomjs.

I did not managed to make 1.5.0-wip to build correctly. I added missing files to build.yml, but all tests fail with `SyntaxError: Property 'toCSS' of object # is not a function` error.