Skip to content

TS files are not included in the coverage with --path option #349

Open

Description

@max-konin

Env:

"ember-cli-code-coverage": "1.0.3",
"ember-cli-typescript": "^4.2.1",

COVERAGE=true ember t works fine and generates accurate coverage reports. But I want to configure my CI workflow with pre-built dist and run tests with --path option.

COVERAGE=true ember b --environment=test
COVERAGE=true ember t --path ./dist

That generates reports w/o .ts files

Repro repo https://github.com/max-konin/coverage-with-path-and-ts-repro. I built a simple component https://github.com/max-konin/coverage-with-path-and-ts-repro/tree/master/app/components
Test coverage report with --path option - https://github.com/max-konin/coverage-with-path-and-ts-repro/actions/runs/1692096928

Activity

  1. rwjblue commented on Jan 18, 2022

    @rwjblue
    Collaborator

    Can you test with the 2.0.0-beta.4 release? There is some additional setup overhead, but this workflow should work a bit better (because we no longer rely on knowing all the files from the build in order to handle coverage).

  2. max-konin commented on Jan 19, 2022

    @max-konin
    Author

    Hey @rwjblue

    2.0.0-beta.4 works fine.

    Thank you!

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