Skip to content

Commit

Permalink
wait for symlink deletion
Browse files Browse the repository at this point in the history
  • Loading branch information
wmmc88 committed Mar 30, 2024
1 parent 7c6aa49 commit 5b90e42
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions crates/wdk-macros/tests/integration_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,9 @@ fn create_symlink_if_nonexistent(link: &Path, target: &Path) {
|| std::fs::read_link(link).expect("read_link of symlink should succeed") != target
{
std::fs::remove_file(link).expect("stale symlink removal should succeed");
// wait for deletion to complete
while link.exists() {}

std::os::windows::fs::symlink_file(target, link).expect("symlink creation should succeed");
} else {
// symlink already exists and points to the correct place
Expand Down

0 comments on commit 5b90e42

Please sign in to comment.