MCPcopy Index your code
hub / github.com/SeleniumHQ/selenium / test

Function test

javascript/selenium-webdriver/test/builder_test.js:88–103  ·  view source on GitHub ↗
(key, options)

Source from the content-addressed store, hash-verified

86 describe('Builder', function () {
87 describe('catches incorrect use of browser options class', function () {
88 function test(key, options) {
89 it(key, async function () {
90 let builder = new Builder().withCapabilities(
91 new Capabilities().set('browserName', 'fake-browser-should-not-try-to-start').set(key, new options()),
92 )
93 try {
94 let driver = await builder.build()
95 await driver.quit()
96 return Promise.reject(Error('should have failed'))
97 } catch (ex) {
98 if (!(ex instanceof error.InvalidArgumentError)) {
99 throw ex
100 }
101 }
102 })
103 }
104
105 test('chromeOptions', chrome.Options)
106 test('moz:firefoxOptions', firefox.Options)

Callers 2

builder_test.jsFile · 0.70
makeProximityFilterFunction · 0.50

Calls 5

ErrorFunction · 0.85
withCapabilitiesMethod · 0.80
setMethod · 0.65
quitMethod · 0.65
buildMethod · 0.45

Tested by

no test coverage detected