File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -536,6 +536,25 @@ fn relative_install_location_without_trailing_slash() {
536536 // NOTE: the install location is relative to the CWD, not the config file
537537 assert_has_not_installed_exe ( & root_t1, "foo" ) ;
538538 assert_has_installed_exe ( & project_t1, "foo" ) ;
539+
540+ // Verify that using the --root CLI argument does not produce the deprecation warning.
541+ // Remove the config file and previous install from the test above.
542+ fs:: remove_file ( root. join ( ".cargo/config.toml" ) ) . unwrap ( ) ;
543+ fs:: remove_dir_all ( & project_t1) . unwrap ( ) ;
544+ cargo_process ( "install --path . --root" )
545+ . arg ( "t1" )
546+ . cwd ( p. root ( ) )
547+ . with_stderr_data ( str![ [ r#"
548+ [INSTALLING] foo v0.0.1 ([ROOT]/foo)
549+ [FINISHED] `release` profile [optimized] target(s) in [ELAPSED]s
550+ [INSTALLING] [ROOT]/foo/t1/bin/foo[EXE]
551+ [INSTALLED] package `foo v0.0.1 ([ROOT]/foo)` (executable `foo[EXE]`)
552+ [WARNING] be sure to add `[ROOT]/foo/t1/bin` to your PATH to be able to run the installed binaries
553+
554+ "# ] ] )
555+ . run ( ) ;
556+ assert_has_not_installed_exe ( & root_t1, "foo" ) ;
557+ assert_has_installed_exe ( & project_t1, "foo" ) ;
539558}
540559
541560#[ cargo_test]
You can’t perform that action at this time.
0 commit comments