Previously, the `SwPush` API docs were using hard-coded code snippets. This commit switches to using code snippets from an actual example app, which ensures that the code shown in the docs will at least continue to compile successfully. PR Close #32139
18 lines
550 B
JavaScript
18 lines
550 B
JavaScript
/**
|
|
* @license
|
|
* Copyright Google Inc. All Rights Reserved.
|
|
*
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
* found in the LICENSE file at https://angular.io/license
|
|
*/
|
|
|
|
const protractorUtils = require('@bazel/protractor/protractor-utils');
|
|
const protractor = require('protractor');
|
|
|
|
module.exports = async function(config) {
|
|
const {port} = await protractorUtils.runServer(config.workspace, config.server, '-port', []);
|
|
const serverUrl = `http://localhost:${port}`;
|
|
|
|
protractor.browser.baseUrl = serverUrl;
|
|
};
|