before_script:
  - phantomjs --version
script: 
  - phantomjs test/test.js

dist: trusty
before_script:
  - phantomjs --version
script: 
  - phantomjs test/test.js

Use Trusty to get phantomjs 2.1
Use Trusty to get phantomjs 2.1