From 6c38d6c1d702f231f937d73a95c206da4448c6ce Mon Sep 17 00:00:00 2001 From: Kevin Willford Date: Thu, 27 Sep 2018 14:07:23 -0600 Subject: [PATCH] Add wait for background operations to complete in modified paths test --- .../Tests/EnlistmentPerTestCase/ModifiedPathsTests.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/GVFS/GVFS.FunctionalTests/Tests/EnlistmentPerTestCase/ModifiedPathsTests.cs b/GVFS/GVFS.FunctionalTests/Tests/EnlistmentPerTestCase/ModifiedPathsTests.cs index e3e9de6a5..ee4c1e060 100644 --- a/GVFS/GVFS.FunctionalTests/Tests/EnlistmentPerTestCase/ModifiedPathsTests.cs +++ b/GVFS/GVFS.FunctionalTests/Tests/EnlistmentPerTestCase/ModifiedPathsTests.cs @@ -193,6 +193,8 @@ public void ModifiedPathsCorrectAfterHardLinking(FileSystemRunner fileSystem) fileSystem.CreateHardLink(hardLinkOutsideRepoToFileInRepoPath, secondFileInRepoPath); hardLinkOutsideRepoToFileInRepoPath.ShouldBeAFile(fileSystem).WithContents(contents); + this.Enlistment.WaitForBackgroundOperations().ShouldEqual(true, "Background operations failed to complete."); + string modifiedPathsDatabase = Path.Combine(this.Enlistment.DotGVFSRoot, TestConstants.Databases.ModifiedPaths); modifiedPathsDatabase.ShouldBeAFile(fileSystem); using (StreamReader reader = new StreamReader(File.Open(modifiedPathsDatabase, FileMode.Open, FileAccess.Read, FileShare.ReadWrite)))