]> git.lizzy.rs Git - rust.git/blobdiff - library/std/tests/env.rs
Rollup merge of #102470 - est31:stabilize_const_char_convert, r=joshtriplett
[rust.git] / library / std / tests / env.rs
index 0e55ec648c9c5707e942c727f7605e8482845303..b095c2dde628536baedfb755d55bea55cc0671f3 100644 (file)
@@ -1,6 +1,5 @@
 use std::env::*;
 use std::ffi::{OsStr, OsString};
-use std::path::PathBuf;
 
 use rand::distributions::Alphanumeric;
 use rand::{thread_rng, Rng};
@@ -79,9 +78,11 @@ fn test_env_set_var() {
 }
 
 #[test]
-#[cfg_attr(any(target_os = "emscripten", target_env = "sgx"), ignore)]
+#[cfg_attr(not(any(unix, windows)), ignore, allow(unused))]
 #[allow(deprecated)]
 fn env_home_dir() {
+    use std::path::PathBuf;
+
     fn var_to_os_string(var: Result<String, VarError>) -> Option<OsString> {
         match var {
             Ok(var) => Some(OsString::from(var)),