Skip to content

Commit

Permalink
Fix SGX CI
Browse files Browse the repository at this point in the history
Broken in #79038
  • Loading branch information
Jethro Beekman committed Dec 1, 2020
1 parent b2dd829 commit b787d72
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion library/std/tests/env.rs
@@ -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};
Expand Down Expand Up @@ -92,6 +91,8 @@ fn env_home_dir() {

cfg_if::cfg_if! {
if #[cfg(unix)] {
use std::path::PathBuf;

let oldhome = var_to_os_string(var("HOME"));

set_var("HOME", "/home/MountainView");
Expand All @@ -109,6 +110,8 @@ fn env_home_dir() {

if let Some(oldhome) = oldhome { set_var("HOME", oldhome); }
} else if #[cfg(windows)] {
use std::path::PathBuf;

let oldhome = var_to_os_string(var("HOME"));
let olduserprofile = var_to_os_string(var("USERPROFILE"));

Expand Down

0 comments on commit b787d72

Please sign in to comment.