Created
February 13, 2017 16:17
-
-
Save evilaliv3/6678fb6b4ccf0b49cdcf6bc5f9bca470 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var specs = JSON.parse(fs.readFileSync('tests/end2end/specs.json')); | |
var q = require("q"); | |
var FirefoxProfile = require("selenium-webdriver/firefox").Profile; | |
var makeFirefoxProfile = function (preferenceMap) { | |
var profile = new FirefoxProfile(); | |
for (var key in preferenceMap) { | |
profile.setPreference(key, preferenceMap[key]); | |
} | |
return q.resolve({ | |
browserName: "firefox", | |
firefox_profile: profile | |
}); | |
}; | |
// The test directory for downloaded files | |
var tmpDir = '/tmp/globaleaks-downloads'; | |
exports.config = { | |
framework: 'jasmine', | |
baseUrl: 'http://127.0.0.1:8082/', | |
troubleshoot: false, | |
directConnect: true, | |
params: { | |
'testFileDownload': true, | |
'verifyFileDownload': true, | |
'tmpDir': tmpDir | |
}, | |
specs: specs, | |
getMultiCapabilities: function() { | |
return q.all([ | |
makeFirefoxProfile({ | |
"intl.accept_language": "en_US", | |
"browser.download.folderList": 2, | |
"browser.download.defaultFolder": tmpDir, | |
"browser.download.downloadDir": tmpDir, | |
"browser.helperApps.neverAsk.saveToDisk": "application/octet-stream" | |
}) | |
]); | |
}, | |
jasmineNodeOpts: { | |
isVerbose: true, | |
includeStackTrace: true, | |
defaultTimeoutInterval: 180000 | |
}, | |
plugins : [{ | |
path: '../../node_modules/protractor-istanbul-plugin' | |
}] | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment