Add support for PhantomJs tests.

Added a simple PhantomJs test.
Update PhantomJS tests to address review comments on #122.
Style fixes in PhantomJS tests.