Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions tests/e2e/utils/puppeteer.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { type Page, launch } from 'puppeteer';
import { execAndWaitForOutputToMatch, killAllProcesses } from './process';
import { stripVTControlCharacters } from 'node:util';

export interface BrowserTestOptions {
project?: string;
Expand All @@ -25,8 +26,11 @@ export async function executeBrowserTest(options: BrowserTestOptions = {}) {
serveArgs.push(`--configuration=${options.configuration}`);
}

const { stdout } = await execAndWaitForOutputToMatch('ng', serveArgs, match);
url = stdout.match(match)?.[1];
const { stdout } = await execAndWaitForOutputToMatch('ng', serveArgs, match, {
...process.env,
'NO_COLOR': '1',
});
url = stripVTControlCharacters(stdout).match(match)?.[1];
if (!url) {
throw new Error('Could not find serving URL');
}
Expand Down