Skip to content

Commit 395a019

Browse files
committed
let's see what this looks like
1 parent 91475e4 commit 395a019

File tree

2 files changed

+6
-16
lines changed

2 files changed

+6
-16
lines changed

site/e2e/playwright.config.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export const port = process.env.CODER_E2E_PORT
66
? Number(process.env.CODER_E2E_PORT)
77
: defaultPort;
88

9-
const coderMain = path.join(__dirname, "../../enterprise/cmd/coder/main.go");
9+
const coderMain = path.join(__dirname, "../../enterprise/cmd/coder");
1010

1111
export const STORAGE_STATE = path.join(__dirname, ".auth.json");
1212

@@ -15,7 +15,6 @@ const localURL = (port: number, path: string): string => {
1515
};
1616

1717
export default defineConfig({
18-
preserveOutput: "failures-only",
1918
projects: [
2019
{
2120
name: "setup",

site/e2e/reporter.ts

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -31,21 +31,15 @@ class CoderReporter implements Reporter {
3131

3232
onStdOut(chunk: string, test?: TestCase, _?: TestResult): void {
3333
if (!test) {
34-
const preserve = this.config?.preserveOutput === "always";
35-
if (preserve) {
36-
console.log(`[stdout] ${chunk.replace(/\n$/g, "")}`);
37-
}
34+
console.log(`[stdout] ${chunk.replace(/\n$/g, "")}`);
3835
return;
3936
}
4037
this.testOutput.get(test.id)!.push([process.stdout, chunk]);
4138
}
4239

4340
onStdErr(chunk: string, test?: TestCase, _?: TestResult): void {
4441
if (!test) {
45-
const preserve = this.config?.preserveOutput === "always";
46-
if (preserve) {
47-
console.error(`[stderr] ${chunk.replace(/\n$/g, "")}`);
48-
}
42+
console.error(`[stderr] ${chunk.replace(/\n$/g, "")}`);
4943
return;
5044
}
5145
this.testOutput.get(test.id)!.push([process.stderr, chunk]);
@@ -66,14 +60,11 @@ class CoderReporter implements Reporter {
6660
this.timedOutTests.push(test);
6761
}
6862

69-
const outputFile = `test-results/debug-pprof-goroutine-${test.title}.txt`;
63+
const fsTestTitle = test.title.replaceAll(" ", "-");
64+
const outputFile = `test-results/debug-pprof-goroutine-${fsTestTitle}.txt`;
7065
await exportDebugPprof(outputFile);
7166

72-
const preserve = this.config?.preserveOutput;
73-
const logOutput =
74-
preserve === "always" ||
75-
(result.status !== "passed" && preserve !== "never");
76-
if (logOutput) {
67+
if (result.status !== "passed") {
7768
console.log(`Data from pprof has been saved to ${outputFile}`);
7869
console.log("==> Output");
7970
const output = this.testOutput.get(test.id)!;

0 commit comments

Comments
 (0)