Obvious/phantomjs — pull request #144 by rajit (2014-03-27 22:07:26+00:00)
Title: Make require('phantomjs') more powerful

This pull request moves more logic into lib/phantomjs.js.

It moves spawn logic from bin/phantomjs into lib/phantomjs.js, without interfering with the old behaviour.
It adds PhantomJsServer 'class', with .start() exported function for starting a selenium server. This is intended to replace the need for a phantomjs-server library and simplify running of phantomjs to just a single spawned process (phantomjs-server spawns the bin from this project, and then the main phantomjs bin).
Added some basic tests to check that the new logic functions. All tests passing.