Skip to content

Add configuration to specify how extensions should be loaded #2345

Closed
@novemberborn

Description

@novemberborn

We need a way for AVA to know whether to load a particular test file (given its extension) as commonjs or module, similar to the "type" field in package.json.

It must not be possible to change how cjs and mjs extensions are loaded. And I have a strong suspicion (but I have not confirmed this) that it's impossible to override the "type" field (which applies to js extensions).

Once configured as module, we then need to import() these test files. This is blocked by #2344.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions