about summary refs log tree commit diff
diff options
context:
space:
mode:
authorChristiaan Dirkx <christiaan@dirkx.email>2021-03-19 20:48:48 +0100
committerChristiaan Dirkx <christiaan@dirkx.email>2021-04-18 09:29:24 +0200
commit0895a693bdaf1472f2c8036abccaa78299ec71cf (patch)
treeea70699cc5954048bd81677211557b194c3e4d57
parentaf0dec279590a44d4542e13913606481084a4e9f (diff)
downloadrust-0895a693bdaf1472f2c8036abccaa78299ec71cf.tar.gz
rust-0895a693bdaf1472f2c8036abccaa78299ec71cf.zip
Fix test `metadata_access_times` to also check for `Unsupported`
-rw-r--r--library/std/src/fs/tests.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/library/std/src/fs/tests.rs b/library/std/src/fs/tests.rs
index 5c969741592..ce8d3a56f7a 100644
--- a/library/std/src/fs/tests.rs
+++ b/library/std/src/fs/tests.rs
@@ -1329,7 +1329,9 @@ fn metadata_access_times() {
         match (a.created(), b.created()) {
             (Ok(t1), Ok(t2)) => assert!(t1 <= t2),
             (Err(e1), Err(e2))
-                if e1.kind() == ErrorKind::Other && e2.kind() == ErrorKind::Other => {}
+                if e1.kind() == ErrorKind::Other && e2.kind() == ErrorKind::Other
+                    || e1.kind() == ErrorKind::Unsupported
+                        && e2.kind() == ErrorKind::Unsupported => {}
             (a, b) => {
                 panic!("creation time must be always supported or not supported: {:?} {:?}", a, b,)
             }