⚠ This page is served via a proxy. Original site: https://github.com
This service does not collect credentials or authentication data.
Skip to content

Allow passing --changed cli option to vitest #32343

@eblocha

Description

@eblocha

Command

test

Description

The unit-test builder does not provide a way to use the --changed vitest option: https://vitest.dev/guide/cli.html#changed. This will analyze the import graph and only run tests affected by a change, which is useful for running a subset of the test suite for pull requests. This option is not available through the vitest configuration file.

Describe the solution you'd like

Add a changed: <string> option to the unit-test builder options which passes --changed <string> to the vitest runner.

Describe alternatives you've considered

I don't think there are any good workarounds. Using @analogjs/vitest-angular exposes vitest directly, but requires more setup and is not an "official" package.

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