Skip to content

Commit

Permalink
Private close log file function
Browse files Browse the repository at this point in the history
  • Loading branch information
manas-yu committed Oct 11, 2024
1 parent 45dd3a0 commit 12c8d79
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,10 @@ class ConsoleLoggerTest {
@Test
fun testConsoleLogger_closeAndReopen_continuesToAppend() {
consoleLogger.e(testTag, "Error before close")

testCoroutineDispatchers.advanceUntilIdle()
consoleLogger.closeLogFile()
// Simulate the logger being closed by clearing internal state
logFile.delete()
testCoroutineDispatchers.advanceUntilIdle()

consoleLogger.e(testTag, "Error after reopen")
Expand Down

0 comments on commit 12c8d79

Please sign in to comment.