-
Notifications
You must be signed in to change notification settings - Fork 29
Running tests in parallel
Nick Abalov edited this page Oct 19, 2015
·
3 revisions
To run tests in parallel using selenium grid you will have to start as many driver instances as many parallel sessions you want. Each driver should started with unique --port
and bound-device-name
values and connected to grid with --nodeconfig
option.
- Download latest selenium release from http://www.seleniumhq.org/download/
- Start Selenium grid
start "SeleniumHub" java -jar C:\Downloads\selenium\selenium-server-standalone.jar -role hub
- Start as many instances of driver as many parallel sessions you want to have (e.g. for 2 parallel sessions we will start 2 drivers):
start Winium.StoreApps.Driver.exe --port=10001 --bound-device-name="Emulator 8.1 WVGA 4 inch 512MB" –-nodeconfig=template.nodeconfig.json --verbose
start Winium.StoreApps.Driver.exe --port=10002 --bound-device-name="Emulator 8.1 WVGA 4 inch" –-nodeconfig=template.nodeconfig.json --verbose
Note that both drivers were started with different --port
and --bound-device-name
values. --nodeconfig
option was used to tell driver to auto register as node on selenium grid. template.nodeconfig.json
is provided with driver and is enough to connect driver as a node to a grid running on a localhost
with default port of 4444
.
- You can list all installed emulators by running
Winium.StoreApps.Driver.exe --bound-device-name=?
. - If you want to run grid on different port or if you want to run node and grid on different hosts, then you will have to edit the configuration file.