protractor Protractor configuration file config file shardTestFiles - Chrome


Example

This configuration lets' you run your total spec files in two browser instances in parallel. It helps reduce the overall test execution time. Change the maxInstances based on your need.

Note: Make sure your tests are independent.

var config = {};
var timeout = 120000;

config.framework = 'jasmine2';
config.allScriptsTimeout = timeout;
config.getPageTimeout = timeout;
config.jasmineNodeOpts.isVerbose = true;
config.jasmineNodeOpts.defaultTimeoutInterval = timeout;
config.specs = ['qa/**/*Spec.js'];
config.capabilities = {
    browserName: 'chrome',
    shardTestFiles: true,
    maxInstances: 2,
    'chromeOptions': {
        'args': ['start-minimized', 'window-size=1920,1080']
    }
};

exports.config = config;