diff options
| author | Graydon Hoare <graydon@mozilla.com> | 2013-01-22 21:41:56 -0800 |
|---|---|---|
| committer | Graydon Hoare <graydon@mozilla.com> | 2013-01-22 21:42:24 -0800 |
| commit | 93e969e356dc8908a7eeef675269149f81a10eed (patch) | |
| tree | 56f7e2e44c6d0ef99e9f23b0ae898a4ad623c815 /src/libstd | |
| parent | 2c870e40744b873bf3205af7b2057cf4f76c3d1f (diff) | |
| download | rust-93e969e356dc8908a7eeef675269149f81a10eed.tar.gz rust-93e969e356dc8908a7eeef675269149f81a10eed.zip | |
std: un-ignore strptime test; fix bug introduced by 1a226f instead.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/time.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libstd/time.rs b/src/libstd/time.rs index 520b7678848..61202401359 100644 --- a/src/libstd/time.rs +++ b/src/libstd/time.rs @@ -576,7 +576,7 @@ priv fn do_strptime(s: &str, format: &str) -> Result<Tm, ~str> { match match_digits_in_range(s, pos, 1u, false, 1_i32, 7_i32) { Some(item) => { let (v, pos) = item; - tm.tm_wday = v-1_i32; + tm.tm_wday = if v == 7 { 0 } else { v }; Ok(pos) } None => Err(~"Invalid day of week") @@ -1025,7 +1025,6 @@ mod tests { } #[test] - #[ignore(reason = "randomred")] fn test_strptime() { os::setenv(~"TZ", ~"America/Los_Angeles"); tzset(); |
