0

I'm using casper.js & backstop.js in Travis CI to run tests with phantom.js. But I would prefer to use slimer.js instead of phantom.js.

Is it possible to do? I tried install it with:

npm install -g slimerjs

and with:

env:
 - SLIMERJSLAUNCHER=$(which firefox) DISPLAY=:99.0 PATH=$TRAVIS_BUILD_DIR/slimerjs:$PATH
addons:
  firefox: "42.0"
before_script:
  - "sh -e /etc/init.d/xvfb start"
  - "echo 'Installing Slimer'"
  - "wget http://download.slimerjs.org/v0.9/0.9.6/slimerjs-0.9.6.zip"
  - "unzip slimerjs-0.9.6.zip"
  - "mv slimerjs-0.9.6 ./slimerjs"

both not working and I get an error:

Gecko error: it seems /usr/local/bin/firefox is not compatible with SlimerJS. See Gecko version compatibility.

I tried different versions of FF specified in application.ini but without any success.

gotbahn
  • 466
  • 2
  • 4
  • 18

1 Answers1

0

I checked the project: https://github.com/JulianBirch/cljs-ajax (referred in: https://github.com/travis-ci/travis-ci/issues/1290) and went over the git history in the .travis.yml file and it seems there is a way to have a green build with slimer 0.9.6.

Copy/pasting the .travis.yml of the last build with slimerjs included (build status is green: https://travis-ci.org/JulianBirch/cljs-ajax/jobs/104345408):

language: clojure
lein: lein2
env:
  - SLIMERJSLAUNCHER=$(which firefox) DISPLAY=:99.0 PATH=$TRAVIS_BUILD_DIR/slimerjs:$PATH
addons:
  firefox: "24.0"
before_script:
  - "sh -e /etc/init.d/xvfb start"
  - "curl https://slimerjs.org/slimerjs-pubkey.gpg | gpg --import"
  - "wget http://download.slimerjs.org/releases/0.9.6/slimerjs-0.9.6-linux-x86_64.tar.bz2"
  - "wget http://download.slimerjs.org/releases/0.9.6/slimerjs-0.9.6-linux-x86_64.tar.bz2.asc"
  - "gpg --verify-files *.asc"
  - "tar jxfv slimerjs-0.9.6-linux-x86_64.tar.bz2"
  - "mv slimerjs-0.9.6 ./slimerjs"
  - "yes | sudo lein2 upgrade 2.5.2"
sudo: required

Well, it might also depend on the VM type you use, but it should be a good starting point.

Anyway, I feel like heading the same direction, so it would be cool if you could share the config working for you.

Peter Butkovic
  • 11,143
  • 10
  • 57
  • 81