pub fn new() -> Fixture {
        // Make sure that all fixtures end up sharing a target dir, and we don't
        // recompile wasm-bindgen and friends many times over.
        static SET_TARGET_DIR: Once = Once::new();
        let target_dir = Path::new(env!("CARGO_MANIFEST_DIR")).join("target");
        SET_TARGET_DIR.call_once(|| {
            env::set_var("CARGO_TARGET_DIR", &target_dir);
        });

        let root = target_dir.join("t");
        fs::create_dir_all(&root).unwrap();
        let dir = TempDir::new_in(&root).unwrap();
        let path = dir.path().join("wasm-pack");
        eprintln!("Created fixture at {}", path.display());
        Fixture {
            dir: ManuallyDrop::new(dir),
            path,
        }
    }
/// Create a new test fixture in a temporary directory.
Create a new test fixture in a temporary directory.
Create a new test fixture in a temporary directory .
pub fn new() -> Fixture {
        // Make sure that all fixtures end up sharing a target dir, and we don't
        // recompile wasm-bindgen and friends many times over.
        static SET_TARGET_DIR: Once = Once::new();
        let target_dir = Path::new(env!("CARGO_MANIFEST_DIR")).join("target");
        SET_TARGET_DIR.call_once(|| {
            env::set_var("CARGO_TARGET_DIR", &target_dir);
        });
        let root = target_dir.join("t");
        fs::create_dir_all(&root).unwrap();
        let dir = TempDir::new_in(&root).unwrap();
        let path = dir.path().join("wasm-pack");
        eprintln!("Created fixture at {}", path.display());
        Fixture {
            dir: ManuallyDrop::new(dir),
            path,
        }
    }
pub fn new ( ) -> Fixture { // Make sure that all fixtures end up sharing a target dir, and we don't // recompile wasm-bindgen and friends many times over. static SET_TARGET_DIR : Once = Once :: new ( ) ; let target_dir = Path :: new ( env ! ( " " ) ) . join ( " " ) ; SET_TARGET_DIR . call_once ( | | { env :: set_var ( " " , & target_dir ) ; } ) ; let root = target_dir . join ( " " ) ; fs :: create_dir_all ( & root ) . unwrap ( ) ; let dir = TempDir :: new_in ( & root ) . unwrap ( ) ; let path = dir . path ( ) . join ( " " ) ; eprintln ! ( " " path display ( ) ) ; Fixture { dir : ManuallyDrop :: new ( dir ) , path , } }
Create a new test fixture in a temporary directory.
Create a new test fixture in a temporary directory .