Skip to content

bug: Test files copied to output target #5788

Closed
ionic-team/ionic-framework
#29666
@mrtnmgs

Description

@mrtnmgs

Prerequisites

Stencil Version

4.18.0

Current Behavior

In a new stencil project, test files are copied over to dist. In some cases, Jest attempts to run these files, creating errors

Expected Behavior

Test files should be excluded of the distribution files (or, if there is a reason to copy them there, be ignored by jest)

System Info

Tested on both Windows and MacOS, npm 10.7.0

Steps to Reproduce

npm test
find dist -type f -name '*.spec.*'
find dist -type f -name '*.e2e.*'

Code Reproduction URL

https://github.com/mrtnmgs/mockbug

Additional Information

This is similar to the bug I logged a couple days ago #5781. I had not realized the problem was much larger than just the mocks.

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