frank0268
frank026811mo ago

Debugging test in VSCode always breaks on line 54 of colors.ts

When debugging tests in VSCode the debugger always breaks on line 54 of colors.ts. This behavior is very annoying as I've set no breakpoints in that file. Is there a way to prevent this behavior?
No description
9 Replies
Leokuma
Leokuma11mo ago
Can you share a snippet of your code so that I can try to reproduce the problem?
frank0268
frank026811mo ago
import { assertEquals } from "https://deno.land/std@0.199.0/assert/assert_equals.ts"; Deno.test("hello", () => { assertEquals("hello", "hello"); });
Debug the test and the VSCode debugger stops at line 54 of Colors.ts
frank0268
frank026811mo ago
No description
frank0268
frank026811mo ago
No description
frank0268
frank026811mo ago
No description
frank0268
frank026811mo ago
Looks like it's happening because of something going on in the import. If I don't import assertEquals, then I don't get the unexpected break in colors.ts.
Leokuma
Leokuma11mo ago
Yea now I can confirm this is a "UX bug" in the Deno VS Code extension I think I've tried to fix it in the past. I'll look into it again as the Deno LSP/Inspector has gone through some updates and maybe it's easier to fix that now
frank0268
frank026811mo ago
Thank you!
frank0268
frank026811mo ago
I filed a formal issue in the Deno VS Code extension: https://github.com/denoland/vscode_deno/issues/896
GitHub
Debugging tests that import assertEquals (and maybe others) breaks ...
Describe the bug When debugging tests in VSCode that import assertEquals the debugger always breaks on line 54 of colors.ts despite not having any explicit breakpoint set for that file/line. To Rep...