about summary refs log tree commit diff
path: root/src/libstd
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2014-08-05 13:11:20 +0000
committerbors <bors@rust-lang.org>2014-08-05 13:11:20 +0000
commitfd02916f0eac754ce63addc22fe2bd2bd1147393 (patch)
tree3bfb498c50319773acdf3e28f065ebddcf59d80c /src/libstd
parentcbdae976898f252852439239fcbcabc6b5f3e454 (diff)
parent2677e5f4a07bf95b3abbc0cc8719e9e4e6b468de (diff)
downloadrust-fd02916f0eac754ce63addc22fe2bd2bd1147393.tar.gz
rust-fd02916f0eac754ce63addc22fe2bd2bd1147393.zip
auto merge of #16243 : alexcrichton/rust/fix-utime-for-windows, r=brson
Apparently the units are in milliseconds, not in seconds!
Diffstat (limited to 'src/libstd')
-rw-r--r--src/libstd/io/fs.rs10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/libstd/io/fs.rs b/src/libstd/io/fs.rs
index 1b2706b3f5b..246ff901f5c 100644
--- a/src/libstd/io/fs.rs
+++ b/src/libstd/io/fs.rs
@@ -1588,8 +1588,7 @@ mod test {
                 "truncate didn't truncate");
     })
 
-    #[test]
-    fn utime() {
+    iotest!(fn utime() {
         let tmpdir = tmpdir();
         let path = tmpdir.join("a");
         check!(File::create(&path));
@@ -1597,17 +1596,16 @@ mod test {
         check!(change_file_times(&path, 1000, 2000));
         assert_eq!(check!(path.stat()).accessed, 1000);
         assert_eq!(check!(path.stat()).modified, 2000);
-    }
+    })
 
-    #[test]
-    fn utime_noexist() {
+    iotest!(fn utime_noexist() {
         let tmpdir = tmpdir();
 
         match change_file_times(&tmpdir.join("a"), 100, 200) {
             Ok(..) => fail!(),
             Err(..) => {}
         }
-    }
+    })
 
     iotest!(fn binary_file() {
         use rand::{StdRng, Rng};