Skip to content

Commit 18155d4

Browse files
committed
Update test input
1 parent 1a9706e commit 18155d4

1 file changed

Lines changed: 9 additions & 4 deletions

File tree

packages/react-refresh/src/__tests__/ReactFreshBabelPlugin-test.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -504,10 +504,15 @@ describe('ReactFreshBabelPlugin', () => {
504504
it("respects Babel's envName option", () => {
505505
const envName = 'random';
506506
expect(() =>
507-
transform(`export default function BabelEnv () { return null };`, {
508-
envName,
509-
skipEnvCheck: false,
510-
}),
507+
transform(
508+
`export default function Foo() {
509+
return <h1>Hi</h1>;
510+
}`,
511+
{
512+
envName,
513+
skipEnvCheck: false,
514+
},
515+
),
511516
).toThrowError(
512517
'React Refresh Babel transform should only be enabled in development environment. ' +
513518
'Instead, the environment is: "' +

0 commit comments

Comments
 (0)