File tree Expand file tree Collapse file tree 3 files changed +12
-2
lines changed
fixtures/function/module-side-effects-external-node-builtin-wrapped-stub Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,11 @@ function unused() {
1010
1111try {
1212 unused ( ) ;
13- } catch { }
13+ } catch ( _err ) {
14+ // Expected: in this fixture we configure `externalBuiltinsRequire: 'stub'`,
15+ // so calling the proxy's `__require()` throws. We swallow the error so the
16+ // test can assert on the generated code (no `node:module` import) without
17+ // failing at runtime.
18+ }
1419
1520module . exports = 1 ;
Original file line number Diff line number Diff line change @@ -6762,7 +6762,12 @@ Generated by [AVA](https://avajs.dev).
67626762 ␊
67636763 try {␊
67646764 unused();␊
6765- } catch {}␊
6765+ } catch (_err) {␊
6766+ // Expected: in this fixture we configure \`externalBuiltinsRequire: 'stub'\`,␊
6767+ // so calling the proxy's \`__require()\` throws. We swallow the error so the␊
6768+ // test can assert on the generated code (no \`node:module\` import) without␊
6769+ // failing at runtime.␊
6770+ }␊
67666771 ␊
67676772 main$1 = 1;␊
67686773 return main$1;␊
You can’t perform that action at this time.
0 commit comments