@@ -27,7 +27,7 @@ use parallel_disk_usage::{
2727 visualizer:: { Color , Coloring } ,
2828} ;
2929#[ cfg( unix) ]
30- use std:: collections:: HashMap ;
30+ use std:: { collections:: HashMap , path :: PathBuf } ;
3131
3232#[ cfg( unix) ]
3333use parallel_disk_usage:: get_size:: { GetBlockCount , GetBlockSize } ;
@@ -932,39 +932,15 @@ fn color_always() {
932932
933933 let ls_colors = LsColors :: from_ls_colors_string ( LS_COLORS ) ;
934934 let map = HashMap :: from ( [
935- (
936- OsStringDisplay :: os_string_from ( "file-a1.txt" ) ,
937- Color :: Normal ,
938- ) ,
939- (
940- OsStringDisplay :: os_string_from ( "file-a2.txt" ) ,
941- Color :: Normal ,
942- ) ,
943- (
944- OsStringDisplay :: os_string_from ( "file-a3.txt" ) ,
945- Color :: Normal ,
946- ) ,
947- (
948- OsStringDisplay :: os_string_from ( "file-b1.txt" ) ,
949- Color :: Normal ,
950- ) ,
951- (
952- OsStringDisplay :: os_string_from ( "file-root.txt" ) ,
953- Color :: Normal ,
954- ) ,
955- ( OsStringDisplay :: os_string_from ( "link-dir" ) , Color :: Symlink ) ,
956- (
957- OsStringDisplay :: os_string_from ( "link-file.txt" ) ,
958- Color :: Symlink ,
959- ) ,
960- (
961- OsStringDisplay :: os_string_from ( "empty-dir-1" ) ,
962- Color :: Directory ,
963- ) ,
964- (
965- OsStringDisplay :: os_string_from ( "empty-dir-2" ) ,
966- Color :: Directory ,
967- ) ,
935+ ( PathBuf :: from ( "./dir-a/file-a1.txt" ) , Color :: Normal ) ,
936+ ( PathBuf :: from ( "./dir-a/file-a2.txt" ) , Color :: Normal ) ,
937+ ( PathBuf :: from ( "./dir-a/subdir-a/file-a3.txt" ) , Color :: Normal ) ,
938+ ( PathBuf :: from ( "./dir-b/file-b1.txt" ) , Color :: Normal ) ,
939+ ( PathBuf :: from ( "./file-root.txt" ) , Color :: Normal ) ,
940+ ( PathBuf :: from ( "./link-dir" ) , Color :: Symlink ) ,
941+ ( PathBuf :: from ( "./link-file.txt" ) , Color :: Symlink ) ,
942+ ( PathBuf :: from ( "./empty-dir-1" ) , Color :: Directory ) ,
943+ ( PathBuf :: from ( "./empty-dir-2" ) , Color :: Directory ) ,
968944 ] ) ;
969945 let coloring = Coloring :: new ( ls_colors, map) ;
970946
0 commit comments