Skip to content

Instantly share code, notes, and snippets.

@zaynelt
Created December 21, 2020 20:49
Show Gist options
  • Save zaynelt/0ed19b3247fd9c91d219c3b9ed379e9b to your computer and use it in GitHub Desktop.
Save zaynelt/0ed19b3247fd9c91d219c3b9ed379e9b to your computer and use it in GitHub Desktop.
const { multiremote } = require('webdriverio');
const nUsers = 5; // lab for 5 users
let port = 4444;
const remoteObject = {};
for (let i = 0; i < nUsers; i += 1) {
const name = `User${i + 1}`;
remoteObject[name] = {
hostname: <YOUR_EXPERIMENT_MACHINE_IP>,
port,
capabilities: {
browserName: 'chrome',
'goog:chromeOptions': {
args: ['disable-notifications']
}
}
};
port +=1;
}
const remote = await multiremote(
remoteObject
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment