Skip to content

Commit cf48911

Browse files
committed
test: add vpr help test and remove win32 ignore from snap test
Add `vpr -h` step to verify help output shows `vp run` help. Remove `ignoredPlatforms: ["win32"]` since vpr works on all platforms.
1 parent 11ed800 commit cf48911

File tree

2 files changed

+34
-1
lines changed

2 files changed

+34
-1
lines changed

packages/cli/snap-tests-global/command-vpr/snap.txt

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,36 @@
1+
> vpr -h # should show vp run help
2+
VITE+ - The Unified Toolchain for the Web
3+
4+
Usage: vp run [OPTIONS] [TASK_SPECIFIER] [ADDITIONAL_ARGS]...
5+
6+
Run tasks.
7+
8+
Arguments:
9+
[TASK_SPECIFIER] `packageName#taskName` or `taskName`. If omitted, lists all available tasks
10+
[ADDITIONAL_ARGS]... Additional arguments to pass to the tasks
11+
12+
Options:
13+
-r, --recursive Select all packages in the workspace
14+
-t, --transitive Select the current package and its transitive dependencies
15+
-w, --workspace-root Select the workspace root package
16+
-F, --filter <FILTERS> Match packages by name, directory, or glob pattern
17+
--ignore-depends-on Do not run dependencies specified in `dependsOn` fields
18+
-v, --verbose Show full detailed summary after execution
19+
--last-details Display the detailed summary of the last run
20+
-h, --help Print help (see more with '--help')
21+
22+
Filter Patterns:
23+
--filter <pattern> Select by package name (e.g. foo, @scope/*)
24+
--filter ./<dir> Select packages under a directory
25+
--filter {<dir>} Same as ./<dir>, but allows traversal suffixes
26+
--filter <pattern>... Select package and its dependencies
27+
--filter ...<pattern> Select package and its dependents
28+
--filter <pattern>^... Select only the dependencies (exclude the package itself)
29+
--filter !<pattern> Exclude packages matching the pattern
30+
31+
Documentation: https://viteplus.dev/guide/run
32+
33+
134
> vpr hello # should fall back to pnpm run when no vite-plus dependency
235

336
> command-vpr@<semver> hello <cwd>

packages/cli/snap-tests-global/command-vpr/steps.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"ignoredPlatforms": ["win32"],
32
"commands": [
3+
"vpr -h # should show vp run help",
44
"vpr hello # should fall back to pnpm run when no vite-plus dependency",
55
"vpr greet --arg1 value1 # should pass through args to pnpm run",
66
"vpr nonexistent # should show pnpm missing script error"

0 commit comments

Comments
 (0)