MCPcopy
hub / github.com/ampproject/amphtml / setupTestcase

Function setupTestcase

testing/init-tests-helpers.js:118–125  ·  view source on GitHub ↗

* Sets up the initial state required by individual test cases.

()

Source from the content-addressed store, hash-verified

116 * Sets up the initial state required by individual test cases.
117 */
118function setupTestcase() {
119 resetTestingState();
120 setTestName(this.currentTest.fullTitle());
121 maybeStubConsoleInfoLogWarn();
122 preventAsyncErrorThrows();
123 warnForConsoleError();
124 stubLogger();
125}
126
127/**
128 * Resets AMP-specific state in the global window object.

Callers

nothing calls this directly

Calls 6

setTestNameFunction · 0.90
preventAsyncErrorThrowsFunction · 0.90
warnForConsoleErrorFunction · 0.90
stubLoggerFunction · 0.90
resetTestingStateFunction · 0.85

Tested by

no test coverage detected