File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {
6262// an uu_app function, so we return the `ls` app.
6363pub fn uu_app ( ) -> Command {
6464 uu_ls:: uu_app ( )
65+ . name ( "dir" )
6566 . override_usage ( format_usage ( & translate ! ( "dir-usage" ) ) )
6667 . about ( translate ! ( "dir-about" ) )
6768}
Original file line number Diff line number Diff line change @@ -1265,7 +1265,7 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {
12651265
12661266pub fn uu_app ( ) -> Command {
12671267 uucore:: clap_localization:: configure_localized_command (
1268- Command :: new ( uucore :: util_name ( ) )
1268+ Command :: new ( "ls" )
12691269 . version ( uucore:: crate_version!( ) )
12701270 . override_usage ( format_usage ( & translate ! ( "ls-usage" ) ) )
12711271 . about ( translate ! ( "ls-about" ) ) ,
Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ pub fn uumain(args: impl uucore::Args) -> UResult<()> {
6262// an uu_app function, so we need this dummy one.
6363pub fn uu_app ( ) -> Command {
6464 uu_ls:: uu_app ( )
65+ . name ( "vdir" )
6566 . override_usage ( format_usage ( & translate ! ( "vdir-usage" ) ) )
6667 . about ( translate ! ( "vdir-about" ) )
6768}
Original file line number Diff line number Diff line change @@ -74,3 +74,12 @@ fn test_help_shows_dir_not_ls() {
7474 "Help should not show 'ls [OPTION]'"
7575 ) ;
7676}
77+
78+ #[ test]
79+ fn test_version ( ) {
80+ new_ucmd ! ( )
81+ . arg ( "--version" )
82+ . succeeds ( )
83+ . no_stderr ( )
84+ . stdout_is ( format ! ( "dir {}\n " , uucore:: crate_version!( ) ) ) ;
85+ }
Original file line number Diff line number Diff line change @@ -74,3 +74,12 @@ fn test_help_shows_vdir_not_ls() {
7474 "Help should not show 'ls [OPTION]'"
7575 ) ;
7676}
77+
78+ #[ test]
79+ fn test_version ( ) {
80+ new_ucmd ! ( )
81+ . arg ( "--version" )
82+ . succeeds ( )
83+ . no_stderr ( )
84+ . stdout_is ( format ! ( "vdir {}\n " , uucore:: crate_version!( ) ) ) ;
85+ }
You can’t perform that action at this time.
0 commit comments