File tree Expand file tree Collapse file tree 4 files changed +11
-3
lines changed
crates/cargo-test-support/src Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -1521,6 +1521,7 @@ fn substitute_macros(input: &str) -> String {
1521
1521
( "[ERROR]" , "error:" ) ,
1522
1522
( "[WARNING]" , "warning:" ) ,
1523
1523
( "[NOTE]" , "note:" ) ,
1524
+ ( "[HELP]" , "help:" ) ,
1524
1525
( "[DOCUMENTING]" , " Documenting" ) ,
1525
1526
( "[FRESH]" , " Fresh" ) ,
1526
1527
( "[UPDATING]" , " Updating" ) ,
Original file line number Diff line number Diff line change @@ -308,7 +308,8 @@ pub trait ArgMatchesExt {
308
308
if self . _is_present ( flag) {
309
309
bail ! (
310
310
"--{} is not allowed in the root of a virtual workspace\n \
311
- note: while this was previously accepted, it didn't actually do anything",
311
+ note: while this was previously accepted, it didn't actually do anything\n \
312
+ help: change the current directory to the package directory, or use the --manifest-path flag to the path of the package",
312
313
flag
313
314
) ;
314
315
}
Original file line number Diff line number Diff line change @@ -1939,15 +1939,17 @@ fn virtual_ws_flags() {
1939
1939
p. cargo ( "build --features=f1" )
1940
1940
. with_stderr (
1941
1941
"[ERROR] --features is not allowed in the root of a virtual workspace\n \
1942
- note: while this was previously accepted, it didn't actually do anything",
1942
+ [NOTE] while this was previously accepted, it didn't actually do anything\n \
1943
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package",
1943
1944
)
1944
1945
. with_status ( 101 )
1945
1946
. run ( ) ;
1946
1947
1947
1948
p. cargo ( "build --no-default-features" )
1948
1949
. with_stderr (
1949
1950
"[ERROR] --no-default-features is not allowed in the root of a virtual workspace\n \
1950
- note: while this was previously accepted, it didn't actually do anything",
1951
+ [NOTE] while this was previously accepted, it didn't actually do anything\n \
1952
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package",
1951
1953
)
1952
1954
. with_status ( 101 )
1953
1955
. run ( ) ;
Original file line number Diff line number Diff line change @@ -57,6 +57,7 @@ fn virtual_no_default_features() {
57
57
"\
58
58
[ERROR] --no-default-features is not allowed in the root of a virtual workspace
59
59
[NOTE] while this was previously accepted, it didn't actually do anything
60
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package
60
61
" ,
61
62
)
62
63
. run ( ) ;
@@ -125,6 +126,7 @@ fn virtual_features() {
125
126
"\
126
127
[ERROR] --features is not allowed in the root of a virtual workspace
127
128
[NOTE] while this was previously accepted, it didn't actually do anything
129
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package
128
130
" ,
129
131
)
130
132
. run ( ) ;
@@ -202,6 +204,7 @@ fn virtual_with_specific() {
202
204
"\
203
205
[ERROR] --features is not allowed in the root of a virtual workspace
204
206
[NOTE] while this was previously accepted, it didn't actually do anything
207
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package
205
208
" ,
206
209
)
207
210
. run ( ) ;
@@ -371,6 +374,7 @@ fn virtual_member_slash() {
371
374
"\
372
375
[ERROR] --features is not allowed in the root of a virtual workspace
373
376
[NOTE] while this was previously accepted, it didn't actually do anything
377
+ [HELP] change the current directory to the package directory, or use the --manifest-path flag to the path of the package
374
378
" ,
375
379
)
376
380
. run ( ) ;
You can’t perform that action at this time.
0 commit comments