File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,9 @@ fn test_metadata(bytes: &[u8], path: &Path) -> Result<()> {
1818
1919// FIXME: Implement stat64 for macos.
2020#[ cfg( not( target_os = "linux" ) ) ]
21- fn test_metadata ( _bytes : & [ u8 ] , _path : & Path ) { }
21+ fn test_metadata ( _bytes : & [ u8 ] , _path : & Path ) -> Result < ( ) > {
22+ Ok ( ( ) )
23+ }
2224
2325fn main ( ) {
2426 let tmp = std:: env:: temp_dir ( ) ;
@@ -56,5 +58,7 @@ fn main() {
5658 // Removing a non-existing file should fail with a "not found" error.
5759 assert_eq ! ( ErrorKind :: NotFound , remove_file( & path) . unwrap_err( ) . kind( ) ) ;
5860 // Reading the metadata of a non-existing file should fail with a "not found" error.
59- assert_eq ! ( ErrorKind :: NotFound , test_metadata( bytes, & path) . unwrap_err( ) . kind( ) ) ;
61+ if cfg ! ( target_os = "linux" ) {
62+ assert_eq ! ( ErrorKind :: NotFound , test_metadata( bytes, & path) . unwrap_err( ) . kind( ) ) ;
63+ }
6064}
You can’t perform that action at this time.
0 commit comments