The user agent string hasn't been 'PhantomJS' for quite some time, so look for
'Headless' and add that to the Firefox launcher. Also redirect requests for
offline-db-worker.js to the current directory.
Signed-off-by: Jason Boyer <JBoyer@equinoxOLI.org>
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Signed-off-by: Jane Sandberg <js7389@princeton.edu>
service.worker.onerror = function(err) {
// avoid spamming unit test runner on failure to connect.
- if (!navigator.userAgent.match(/PhantomJS/)) {
+ if (!navigator.userAgent.match(/Headless/)) {
console.error('Error loading shared worker', err);
}
service.cannotConnect = true;
'test/unit/**/*.js'
],
+ proxies: {
+ '/js/ui/default/staff/offline-db-worker.js' : 'offline-db-worker.js'
+ },
+
// test results reporter to use
// possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
reporters: ['spec'], // detailed report
flags: [
'-headless',
],
+ prefs: {
+ 'privacy.resistFingerprinting': false,
+ 'general.useragent.override': 'FirefoxHeadless'
+ },
}
},