MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / getTestHook

Function getTestHook

javascript/selenium-webdriver/testing/index.js:590–601  ·  view source on GitHub ↗

* @param {string} name * @return {!Function} * @throws {TypeError}

(name)

Source from the content-addressed store, hash-verified

588 * @throws {TypeError}
589 */
590function getTestHook(name) {
591 let fn = global[name]
592 let type = typeof fn
593 if (type !== 'function') {
594 throw TypeError(
595 `Expected global.${name} to be a function, but is ${type}.` +
596 ' This can happen if you try using this module when running with' +
597 ' node directly instead of using jasmine or mocha',
598 )
599 }
600 return fn
601}
602
603/**
604 * Bazel's hermetic java, from `SE_BAZEL_JAVA_LOCATION` (a file holding the `$(JAVA)` path).

Callers 1

ignoreFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected