Skip to content

Commit

Permalink
Fix concurrncy
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobsen9026 committed May 1, 2024
1 parent 0e354fe commit a9a2e70
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 11 deletions.
16 changes: 6 additions & 10 deletions BLAZAM.Tests/Updates/UpdateTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,22 @@ public async void Update_Returns_ValidDownload()
await latest.Download(null);

Assert.True(latest?.UpdateFile.Exists);
Update_Stages_OK(latest);
Update_Cleanup_OK(latest);
await Update_Stages_OK(latest);
await Update_Cleanup_OK(latest);
}
private async void Update_Stages_OK(ApplicationUpdate latest)
private async Task Update_Stages_OK(ApplicationUpdate latest)
{

await latest.ExtractFiles(null);
Assert.True(latest.UpdateStagingDirectory.Files.Count > 2);

}
private async void Update_Cleanup_OK(ApplicationUpdate latest)
private async Task Update_Cleanup_OK(ApplicationUpdate latest)
{

await latest.CleanStaging(null);
try
{
latest.UpdateFile.Delete();
Assert.True(!latest.UpdateFile.Exists);
}
catch { }
latest.UpdateFile.Delete();
Assert.True(!latest.UpdateFile.Exists);
Assert.True(latest.UpdateStagingDirectory.Files.Count == 0);
}
}
Expand Down
2 changes: 1 addition & 1 deletion BLAZAM/BLAZAM.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<ImplicitUsings>enable</ImplicitUsings>
<ServerGarbageCollection>false</ServerGarbageCollection>
<AssemblyVersion>0.9.2</AssemblyVersion>
<Version>2024.05.01.2302</Version>
<Version>2024.05.01.2331</Version>
<IncludeSourceRevisionInInformationalVersion>false</IncludeSourceRevisionInInformationalVersion>
<RootNamespace>BLAZAM</RootNamespace>
<GenerateDocumentationFile>False</GenerateDocumentationFile>
Expand Down

0 comments on commit a9a2e70

Please sign in to comment.