stencil icon indicating copy to clipboard operation
stencil copied to clipboard

bug: single spec component test isnt working

Open womblep opened this issue 9 months ago • 3 comments

Prerequisites

Stencil Version

v4.35.1

Current Behavior

npx stencil test --spec -- src/components/my-component/my-component.spec.ts

comes up with the error: [35:21.5] @stencil/core [35:21.8] v4.35.1

[ ERROR ] Testing requires either the --spec or --e2e command line flags, or both. For example, to run unit tests, use the command: stencil test --spec

I took the command line from here https://stenciljs.com/docs/testing/stencil-testrunner/overview#command-line-arguments

Expected Behavior

It should run the spec test for that component

System Info

System: node 24.2.0
    Platform: windows (10.0.26100)
   CPU Model: AMD Ryzen 7 5800X 8-Core Processor              (16 cpus)
    Compiler: D:\RubymineProjects\SecureCall\sc-client-component\node_modules\@stencil\core\compiler\stencil.js
       Build: 1750123236
     Stencil: 4.35.1
  TypeScript: 5.5.4
      Rollup: 4.34.9
      Parse5: 7.2.1
      jQuery: 4.0.0-pre
      Terser: 5.37.0

Steps to Reproduce

It looks like any single component test fails

Code Reproduction URL

running npm init stencil@latest generates something that fails when using the command

Additional Information

No response

womblep avatar Jun 18 '25 04:06 womblep

It looks like any single component test fails

We would have caught this in our pipelines then. Mind providing a simple minimal reproduction case?

christian-bromann avatar Jun 19 '25 16:06 christian-bromann

npm init stencil@latest produces a minimal test case that fails Here is the url of a repo https://github.com/womblep/stencil-test

womblep avatar Jun 20 '25 01:06 womblep

I'm guessing this is only an issue in Windows? I cannot recreate on Mac

Image

johnjenkins avatar Dec 09 '25 15:12 johnjenkins