@@ -1640,6 +1640,10 @@ fn test_file_times() {
16401640 use crate :: os:: ios:: fs:: FileTimesExt ;
16411641 #[ cfg( target_os = "macos" ) ]
16421642 use crate :: os:: macos:: fs:: FileTimesExt ;
1643+ #[ cfg( target_os = "tvos" ) ]
1644+ use crate :: os:: tvos:: fs:: FileTimesExt ;
1645+ #[ cfg( target_os = "tvos" ) ]
1646+ use crate :: os:: tvos:: fs:: FileTimesExt ;
16431647 #[ cfg( target_os = "watchos" ) ]
16441648 use crate :: os:: watchos:: fs:: FileTimesExt ;
16451649 #[ cfg( windows) ]
@@ -1651,9 +1655,21 @@ fn test_file_times() {
16511655 let accessed = SystemTime :: UNIX_EPOCH + Duration :: from_secs ( 12345 ) ;
16521656 let modified = SystemTime :: UNIX_EPOCH + Duration :: from_secs ( 54321 ) ;
16531657 times = times. set_accessed ( accessed) . set_modified ( modified) ;
1654- #[ cfg( any( windows, target_os = "macos" , target_os = "ios" , target_os = "watchos" ) ) ]
1658+ #[ cfg( any(
1659+ windows,
1660+ target_os = "macos" ,
1661+ target_os = "ios" ,
1662+ target_os = "watchos" ,
1663+ target_os = "tvos" ,
1664+ ) ) ]
16551665 let created = SystemTime :: UNIX_EPOCH + Duration :: from_secs ( 32123 ) ;
1656- #[ cfg( any( windows, target_os = "macos" , target_os = "ios" , target_os = "watchos" ) ) ]
1666+ #[ cfg( any(
1667+ windows,
1668+ target_os = "macos" ,
1669+ target_os = "ios" ,
1670+ target_os = "watchos" ,
1671+ target_os = "tvos" ,
1672+ ) ) ]
16571673 {
16581674 times = times. set_created ( created) ;
16591675 }
@@ -1678,7 +1694,13 @@ fn test_file_times() {
16781694 let metadata = file. metadata ( ) . unwrap ( ) ;
16791695 assert_eq ! ( metadata. accessed( ) . unwrap( ) , accessed) ;
16801696 assert_eq ! ( metadata. modified( ) . unwrap( ) , modified) ;
1681- #[ cfg( any( windows, target_os = "macos" , target_os = "ios" , target_os = "watchos" ) ) ]
1697+ #[ cfg( any(
1698+ windows,
1699+ target_os = "macos" ,
1700+ target_os = "ios" ,
1701+ target_os = "watchos" ,
1702+ target_os = "tvos" ,
1703+ ) ) ]
16821704 {
16831705 assert_eq ! ( metadata. created( ) . unwrap( ) , created) ;
16841706 }
0 commit comments