Skip to content

bug: Cannot find module '@stencil/core/testing/jest-preset' after upgrading to Stencil 4.19.2 #5896

@geovanesantana

Description

@geovanesantana

Prerequisites

Stencil Version

4.19.2

Current Behavior

This error occurs when trying to import moduleNameMapper from @stencil/core/testing/jest-preset in the Stencil configuration file:

import { moduleNameMapper } from '@stencil/core/testing/jest-preset';

### Expected Behavior

Should work as it did in previous versions, allowing the use of `moduleNameMapper` from `@stencil/core/testing/jest-preset`.

### System Info

```shell
Node 20.11.1
PNPM 9.3.0
CPU Model: Apple M3
Stencil: 4.19.2

Steps to Reproduce

  1. Upgrade @stencil/core to version 4.19.2
  2. Attempt imports moduleNameMapper from @stencil/core/testing/jest-preset
  3. Observe the mentioned error

Code Reproduction URL

n/a

Additional Information

Error: Cannot find module
@tc/stencil-library:build:            '/Users/xxxx/Documents/work/cars/node_modules/@stencil/core/testing/jest-preset' at

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: ValidatedThis PR or Issue is verified to be a bug within Stencil

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions