GitNexus/gitnexus/test/unit/scope-resolution/go
Gergo Magyar b9008024ab fix(test): remove TOCTOU file-system race in golden test + format
CodeQL flagged a high-severity 'potential file system race condition': the golden
test did fs.existsSync(GOLDEN_FILE) then later writeFileSync/readFileSync on it.
Replace the existsSync-then-use with a single race-free read (ENOENT => missing),
reusing the read content for the compare path. Behaviour is unchanged (the pure
resolveGoldenAction helper still decides regenerate/compare/fail). Also applies
prettier formatting to the file (fixes the quality/format check).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-05-30 11:20:51 +00:00
..
go-captures-golden.test.ts fix(test): remove TOCTOU file-system race in golden test + format 2026-05-30 11:20:51 +00:00
go-captures-smoke.test.ts test(go): strengthen func_literal smoke case to a positive receiver assertion (#1848 U3) 2026-05-30 11:02:44 +00:00
go-hooks.test.ts feat(go): implement scope resolution hooks for Go language support (#1302) 2026-05-04 07:29:11 +01:00
go-imports.test.ts feat(go): implement scope resolution hooks for Go language support (#1302) 2026-05-04 07:29:11 +01:00
go-package-siblings.test.ts feat(go): implement scope resolution hooks for Go language support (#1302) 2026-05-04 07:29:11 +01:00
go-range-binding-null-guard.test.ts fix(go): use loose equality for Array.find() null checks (#1384) 2026-05-06 17:57:19 +01:00
go-type-binding.test.ts fix(go): use loose equality for Array.find() null checks (#1384) 2026-05-06 17:57:19 +01:00