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

fix(test): add slice method to filename to make them portable (#16482)

In order for test cases to pass regardless of each individual's environment,
this commit adds calls to `slice` method when printing the filenames so
we can avoid getting `console.log` to truncate them.

Fixes #16305
This commit is contained in:
Shogo Hida 2022-10-31 12:46:59 +09:00 committed by GitHub
parent 05eb4d1084
commit 80ed54a4b6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -2,7 +2,7 @@ addEventListener("error", (event) => {
console.log({
cancelable: event.cancelable,
message: event.message,
filename: event.filename,
filename: event.filename?.slice?.(-100),
lineno: event.lineno,
colno: event.colno,
error: event.error,

View file

@ -2,7 +2,7 @@ addEventListener("error", (event) => {
console.log({
cancelable: event.cancelable,
message: event.message,
filename: event.filename,
filename: event.filename?.slice?.(-100),
lineno: event.lineno,
colno: event.colno,
error: event.error,