tools: run-tests: FlushAndPurgeOnCleanup

This commit is contained in:
Bill Zissimopoulos
2018-04-19 11:17:41 -07:00
parent 740411d604
commit 5b72b4ad4a
2 changed files with 16 additions and 2 deletions

View File

@ -304,12 +304,14 @@ static void exec_rename_dir_dotest(ULONG Flags, PWSTR Prefix, ULONG FileInfoTime
ASSERT(CreateDirectoryW(Dir1Path, 0));
ExecHelper(FilePath, 1000, &Process);
ExecHelper(FilePath, 2000, &Process);
Sleep(1000); /* give time for file handles to be closed (FlushAndPurgeOnCleanup) */
ASSERT(MoveFileExW(Dir1Path, Dir2Path, MOVEFILE_REPLACE_EXISTING));
ASSERT(MoveFileExW(Dir2Path, Dir1Path, MOVEFILE_REPLACE_EXISTING));
WaitHelper(Process, 1000);
WaitHelper(Process, 2000);
ASSERT(DeleteFileW(FilePath));