1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 23:34:47 -05:00

chore(tests): fix flaky test_no_lock (#18206)

The test output capturing is known to be flaky.

Closes #18199
This commit is contained in:
David Sherret 2023-03-15 11:03:36 -04:00 committed by GitHub
parent 7070b8ed50
commit 5c505316b3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 12 additions and 10 deletions

View file

@ -1,6 +1,5 @@
Download http://localhost:4545/lockfile/basic/mod.ts Download http://localhost:4545/lockfile/basic/mod.ts
Check file:///[WILDCARD]/main.bench.ts Check file:///[WILDCARD]/main.bench.ts
5
cpu: [WILDCARD] cpu: [WILDCARD]
runtime: [WILDCARD] runtime: [WILDCARD]

View file

@ -1,8 +1,8 @@
import "./main.ts"; import { getValue } from "mod";
Deno.bench("bench", () => { Deno.bench("bench", () => {
const testing = 1 + 2; const testing = 1 + getValue();
if (testing !== 3) { if (testing !== 6) {
throw "FAIL"; throw "FAIL";
} }
}); });

View file

@ -1,8 +1,8 @@
import "./main.ts"; import { getValue } from "mod";
Deno.test("test", () => { Deno.test("test", () => {
const testing = 1 + 2; const testing = 1 + getValue();
if (testing !== 3) { if (testing !== 6) {
throw "FAIL"; throw "FAIL";
} }
}); });

View file

@ -1 +1,3 @@
import "mod"; import { getValue } from "mod";
console.log(getValue());

View file

@ -1 +1,3 @@
console.log(5); export function getValue() {
return 5;
}

View file

@ -1,5 +1,4 @@
Download http://localhost:4545/lockfile/basic/mod.ts Download http://localhost:4545/lockfile/basic/mod.ts
Check file:///[WILDCARD]/main.test.ts Check file:///[WILDCARD]/main.test.ts
5
running 1 test from ./main.test.ts running 1 test from ./main.test.ts
[WILDCARD] [WILDCARD]