import '@testing-library/jest-dom'; import React from 'react'; // esbuild-jest compiles JSX with the classic runtime (React.createElement), // while source files rely on the automatic runtime and never import React. // Expose React globally so rendering components in tests works. (globalThis as Record).React = React;