Skip to content

Commit

Permalink
fix: use targets and real browsers
Browse files Browse the repository at this point in the history
  • Loading branch information
petey committed Sep 11, 2017
1 parent 740410d commit 0c24b3f
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 7 deletions.
7 changes: 7 additions & 0 deletions bin/setup_chrome.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/sh

wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
apt-get update -qy
apt-get install -qy google-chrome-stable
ln -s /usr/bin/google-chrome /usr/bin/chrome
5 changes: 5 additions & 0 deletions bin/setup_firefox.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/sh
cd /tmp
wget https://download-installer.cdn.mozilla.net/pub/firefox/releases/55.0/linux-x86_64/en-US/firefox-55.0.tar.bz2
tar xvf firefox-55.0.tar.bz2
ln -s /tmp/firefox/firefox /usr/bin/firefox
6 changes: 3 additions & 3 deletions config/targets.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

module.exports = {
browsers: [
// 'last 1 Chrome versions'
// 'last 1 Firefox versions'
// 'last 1 Safari versions'
'last 1 Chrome versions',
'last 1 Firefox versions',
'last 1 Safari versions'
]
};
1 change: 1 addition & 0 deletions screwdriver.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
steps:
- install: npm install
- bower: npm install bower && ./node_modules/.bin/bower install --allow-root
- install-browsers: ./bin/setup_chrome.sh
- test: npm test

# Publish the package to GitHub and build docker image
Expand Down
19 changes: 15 additions & 4 deletions testem.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,21 @@ module.exports = {
test_page: 'tests/index.html?hidepassed',
disable_watching: true,
launch_in_ci: [
'PhantomJS'
'Chrome'
],
launch_in_dev: [
'PhantomJS',
'Chrome'
]
'Chrome',
'Firefox'
],
"browser_args": {
"Chrome": [
"--headless",
"--disable-gpu",
"--remote-debugging-port=9222",
"--no-sandbox"
],
"Firefox": [
"-headless"
]
}
};

0 comments on commit 0c24b3f

Please sign in to comment.