mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 15:23:46 +00:00
Rollup merge of #79105 - petrochenkov:winlink, r=shepmaster
std: Fix test `symlink_hard_link` on Windows The test was introduced in https://github.com/rust-lang/rust/pull/78026 and fails depending on Windows version and admin rights. Other similar tests check for symlink creation permissions before doing anything, this PR performs the same check for `symlink_hard_link` as well.
This commit is contained in:
commit
a207801551
@ -1341,6 +1341,9 @@ fn metadata_access_times() {
|
||||
#[test]
|
||||
fn symlink_hard_link() {
|
||||
let tmpdir = tmpdir();
|
||||
if !got_symlink_permission(&tmpdir) {
|
||||
return;
|
||||
};
|
||||
|
||||
// Create "file", a file.
|
||||
check!(fs::File::create(tmpdir.join("file")));
|
||||
|
Loading…
Reference in New Issue
Block a user