Skip to content

TypeError: A dynamic import callback was invoked without --experimental-vm-modules #116

Description

@martinchrzansaxo

When running the new version 10.x in test running jest 30.x, I am getting this error

TypeError: A dynamic import callback was invoked without --experimental-vm-modules

It is pretty simple test:

import looksSame from 'looks-same';

describe("imageComp", ()=> {
 it('should return true for identical images', async () => {
     const path1 =  '__test_images__/original_image.png';
     const path2 =  '__test_images__/same_image.png';
     const { equal, diffImage, differentPixels } = await looksSame(path1, path2, {
        createDiffImage: true,
    });
    expect(equal).toBe(true);
}});

Any way to avoid this flag? Enabling it breaks my other tests so I would like to avoid that

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions