remote_runner: Avoid duplication in task list

pull/5020/head
Richard Hansen 2021-05-02 15:04:12 -04:00
parent 59be8d5c05
commit 1f3a831cc3
1 changed files with 27 additions and 31 deletions

View File

@ -128,40 +128,36 @@ const sauceTestWorker = async.queue((testSettings, callback) => {
}); });
}, 6); // run 6 tests in parrallel }, 6); // run 6 tests in parrallel
if (!isAdminRunner) { [
sauceTestWorker.push({ {
platform: 'OS X 10.15',
browserName: 'safari',
version: '13.1',
},
...(isAdminRunner ? [] : [
{
platform: 'Windows 10', platform: 'Windows 10',
browserName: 'firefox', browserName: 'firefox',
version: '84.0', version: '84.0',
}); },
sauceTestWorker.push({ {
platform: 'Windows 7', platform: 'Windows 7',
browserName: 'chrome', browserName: 'chrome',
version: '55.0', version: '55.0',
args: ['--use-fake-device-for-media-stream'], args: ['--use-fake-device-for-media-stream'],
}); },
sauceTestWorker.push({ {
platform: 'OS X 10.15',
browserName: 'safari',
version: '13.1',
});
sauceTestWorker.push({
platform: 'Windows 10', platform: 'Windows 10',
browserName: 'microsoftedge', browserName: 'microsoftedge',
version: '83.0', version: '83.0',
}); },
sauceTestWorker.push({ {
platform: 'Windows 7', platform: 'Windows 7',
browserName: 'firefox', browserName: 'firefox',
version: '78.0', version: '78.0',
}); },
} else { ]),
sauceTestWorker.push({ ].forEach((task) => sauceTestWorker.push(task));
platform: 'OS X 10.15',
browserName: 'safari',
version: '13.1',
});
}
sauceTestWorker.drain(() => { sauceTestWorker.drain(() => {
process.exit(allTestsPassed ? 0 : 1); process.exit(allTestsPassed ? 0 : 1);