-
Notifications
You must be signed in to change notification settings - Fork 352
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support for tempfile crate on UNIX hosts
Co-authored-by: Jefffrey <[email protected]> Co-authored-by: Ralf Jung <[email protected]>
- Loading branch information
1 parent
750d82d
commit 06add70
Showing
4 changed files
with
181 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
//@ignore-target-windows: File handling is not implemented yet | ||
//@ignore-host-windows: Only supported for UNIX hosts | ||
//@compile-flags: -Zmiri-disable-isolation | ||
|
||
#[path = "../utils/mod.rs"] | ||
mod utils; | ||
|
||
/// Test that the [`tempfile`] crate is compatible with miri for UNIX hosts and targets | ||
fn main() { | ||
test_tempfile(); | ||
test_tempfile_in(); | ||
} | ||
|
||
fn test_tempfile() { | ||
tempfile::tempfile().unwrap(); | ||
} | ||
|
||
fn test_tempfile_in() { | ||
let dir_path = utils::tmp(); | ||
tempfile::tempfile_in(dir_path).unwrap(); | ||
} |