From 485a7c4207e0b8e44197edd8aeca6a1415c83ac3 Mon Sep 17 00:00:00 2001 From: Ebere Abanonu Date: Tue, 28 Mar 2023 12:18:07 +0100 Subject: [PATCH] [71-74] `FileSinkSpec` (#6619) * [71-74] `FileSinkSpec` * Revert "[71-74] `FileSinkSpec`" This reverts commit 6ef392b201e5499ad3b8d7d2368e3933ef2ffbd3. * fix --------- Co-authored-by: Aaron Stannard --- src/core/Akka.Streams.Tests/IO/FileSinkSpec.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/Akka.Streams.Tests/IO/FileSinkSpec.cs b/src/core/Akka.Streams.Tests/IO/FileSinkSpec.cs index 2cbd839a688..48887c5d7f3 100644 --- a/src/core/Akka.Streams.Tests/IO/FileSinkSpec.cs +++ b/src/core/Akka.Streams.Tests/IO/FileSinkSpec.cs @@ -408,9 +408,9 @@ await AwaitAssertAsync(() => } [Fact] - public void SynchronousFileSink_should_write_buffered_element_if_manual_flush_is_called() + public async Task SynchronousFileSink_should_write_buffered_element_if_manual_flush_is_called() { - this.AssertAllStagesStopped(async() => + await this.AssertAllStagesStoppedAsync(async() => { await TargetFileAsync(async f => { @@ -468,7 +468,7 @@ private async Task TargetFileAsync( { // this is the proverbial stream kill switch, make sure that all streams // are dead so that the file handle would be released - await this.AssertAllStagesStoppedAsync(async() => { }, materializer); + await this.AssertAllStagesStoppedAsync(() => { return Task.CompletedTask; }, materializer); //give the system enough time to shutdown and release the file handle await Task.Delay(500);