【问题标题】:Protractor test suites and capabilities量角器测试套件和功能
【发布时间】:2018-07-17 15:55:45
【问题描述】:

我希望能够使用特定的浏览器配置运行特定的套件,这可能吗?我尝试以下代码,但不幸的是 when 套件被指定功能 specs 字段被忽略,两个测试套件都在两个浏览器配置中执行。

{
    multiCapabilities: [{
        browserName: 'chrome',
            'chromeOptions': browserConfig.winOsSettings,
            specs: './e2e/test-suites/regression-test-suite/**/*.win.os.e2e-spec.ts'
        }, {
        browserName: 'chrome',
            'chromeOptions': browserConfig.ubuntuOsSettings,
            specs: './e2e/test-suites/regression-test-suite/**/*.ubuntu.e2e-spec.ts'
       }
    ],
    suites: {
        ubuntu_tests: '../e2e/test-suites/regression-test-suite/**/*.win.os.e2e-spec.ts',
        windows_tests: './e2e/test-suites/regression-test-suite/**/*.ubuntu.e2e-spec.ts',
    }
}

【问题讨论】:

    标签: javascript angular protractor


    【解决方案1】:

    试试下面的代码

    multiCapabilities: [{
      'browserName': 'chrome',
      'chromeOptions':browserConfig.winOsSettings,
      specs: './e2e/test-suites/regression-test-suite/**/*.win.os.e2e-spec.ts'
    }, {
      'browserName': 'chrome',
      'chromeOptions': browserConfig.ubuntuOsSettings,
      specs: './e2e/test-suites/regression-test-suite/**/*.ubuntu.e2e-spec.ts'
    }],
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2018-11-19
      • 1970-01-01
      • 2016-02-11
      • 2011-07-02
      • 2019-07-19
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多