]> git.lizzy.rs Git - rust.git/blobdiff - src/libstd/env.rs
SGX target: fix std unit tests
[rust.git] / src / libstd / env.rs
index 97c67f562a7dfac171052b854ec03ce49b91219f..f723a2b0bb281eeab9677338cc2cefb40df7ac44 100644 (file)
@@ -975,7 +975,7 @@ mod tests {
     use crate::path::Path;
 
     #[test]
-    #[cfg_attr(target_os = "emscripten", ignore)]
+    #[cfg_attr(any(target_os = "emscripten", target_env = "sgx"), ignore)]
     fn test_self_exe_path() {
         let path = current_exe();
         assert!(path.is_ok());
@@ -989,6 +989,7 @@ fn test_self_exe_path() {
     fn test() {
         assert!((!Path::new("test-path").is_absolute()));
 
+        #[cfg(not(target_env = "sgx"))]
         current_dir().unwrap();
     }