diff --git a/Sources/XCTest/Public/XCTestCase.swift b/Sources/XCTest/Public/XCTestCase.swift index 2d899b91..f296977e 100644 --- a/Sources/XCTest/Public/XCTestCase.swift +++ b/Sources/XCTest/Public/XCTestCase.swift @@ -141,6 +141,8 @@ open class XCTestCase: XCTest { let allExpectations = XCTWaiter.subsystemQueue.sync { _allExpectations } failIfExpectationsNotWaitedFor(allExpectations) + cleanUpExpectations() + testRun.stop() XCTCurrentTestCase = nil }