I want a unit-test framework for JavaScript which runs in the browser. Not with an external browser-automation system as in Selenium, or a non-browser JS environment, but just one .html which loads the test framework and test suite and displays the results in that page. My searches have found only the other two kinds.
I am primarily interested in testing JavaScript code for expected results and not crashing, not DOM/events or visual appearance.
Nice-to-haves:
The motivation for the requirements is:
You can run Selenium in the browser only. Download Selenium Core 1.01. Upload the unzipped files to the domain you want to test. Open /core/TestRunner.html and start the browser only frontend of Selenium :)
I use this kind of test in several projects. It's perfect to have only one place to store and to run tests. You can trigger those these by cronjobs and capture the results as well. I extended it a lot and I save the results to a Database and take automatically screenshots with JS when errors occur.
If this kind of running Selenium is still supported in version > 2.0, I don't know. Here is a tiny documentation.