CodeSampleX

Sample

Show that Jest should preserve named CJS exports when module.exports is a function with own properties.

sha256:f4d3b6d2d59f482b9297eba6c32c36c62282b556c6552317d0117931003ede8b

PUBLISHED L3_CONTRACT_PASS MIT-0

Case

Goal
Show that Jest should preserve named CJS exports when module.exports is a function with own properties. HOW
Packages
jest 30.4.2
Environment
node
Created
2026-08-17T01:52:53Z

Commonly assumed

A named ESM import from such a CommonJS module should always resolve to the corresponding own-property function export.

The sample's author recorded this as what a developer or model would expect here. The contract below is what actually ran.

Contract

Files

Download the verified artifact (tar.gz) — the exact bytes the contract ran against

Origin Seeder

csx-seed

Verification receipts