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

Method setTestUrl

build-system/tasks/e2e/describes-e2e.js:620–633  ·  view source on GitHub ↗

* Translate relative fixture specs into localhost test URL. * @param {!TestSpec} spec * @return {!TestSpec}

(spec)

Source from the content-addressed store, hash-verified

618 * @return {!TestSpec}
619 */
620 setTestUrl(spec) {
621 const {fixture, testUrl} = spec;
622
623 if (testUrl) {
624 throw new Error(
625 'Setting `testUrl` directly is no longer permitted in e2e tests; please use `fixture` instead'
626 );
627 }
628
629 return {
630 ...spec,
631 testUrl: `http://localhost:8000/test/fixtures/e2e/${fixture}`,
632 };
633 }
634}
635
636/**

Callers 1

constructorMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected