MCPcopy Create free account
hub / github.com/ampproject/amphtml / setup

Method setup

testing/describes.js:563–573  ·  view source on GitHub ↗

@override

(env)

Source from the content-addressed store, hash-verified

561
562 /** @override */
563 setup(env) {
564 env.win = new FakeWindow(this.spec.win || {});
565
566 if (this.spec.mockFetch !== false) {
567 attachFetchMock(env);
568 }
569
570 if (!this.spec.Promise) {
571 env.win.Promise = window.Promise;
572 }
573 }
574
575 /** @override */
576 teardown(unusedEnv) {

Callers

nothing calls this directly

Calls 1

attachFetchMockFunction · 0.85

Tested by

no test coverage detected