PhantomJS is a headless WebKit scriptable with a JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG.
Phantom can be run in your favourite shell on Windows, OS X or Linux.
phantomjs runner_script.js param1 param2 2000
All other parameters passed will be propagated to runner script.
Phantom has several modules that are used for automation and testing:
Concept similar to node.js, but modules can't be shared.
More or less everything needed for basic testing:
open
evaluate
render
viewportSize
Phantom can be used with any testing framework, many of which already have runner scripts implemented available on PhantomJS web page.
Similar concept also has CasperJS, which is a wrapper around PhantomJS and adds testing APIs so no additional test frameworks are needed.
Phantom.js was a natural way to go for testing HTML and JavaScript tasks. QUnit was chosen for simplicity, previous experience and community support (i.e. existent runner script :) ).
Problems:
http://slides.com/djerbic/phantom-js/
http://phantomjs.org/