Files
swift-composable-architectu…/Tests/ComposableArchitectureTests/Internal/BaseTCATestCase.swift
2025-04-01 23:53:03 +00:00

18 lines
438 B
Swift

@_spi(Internals) @_spi(Logging) import ComposableArchitecture
import XCTest
class BaseTCATestCase: XCTestCase {
override func tearDown() async throws {
try await super.tearDown()
let description = "\(self)"
_cancellationCancellables.withValue {
XCTAssertEqual($0.count, 0, description)
$0.removeAll()
}
await MainActor.run {
Logger.shared.isEnabled = false
Logger.shared.clear()
}
}
}