Fix PhantomJS and Rhino tests for Travis.