From 5b8ecdc14b2bdba8ce4f418ab7f677caea7cf1aa Mon Sep 17 00:00:00 2001 From: David Grove Date: Wed, 17 Aug 2016 17:57:00 -0400 Subject: [PATCH] enable Dispatch tests in TestNSOperationQueue --- TestFoundation/TestNSOperationQueue.swift | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/TestFoundation/TestNSOperationQueue.swift b/TestFoundation/TestNSOperationQueue.swift index bc303ffc64..cc74b86cf5 100644 --- a/TestFoundation/TestNSOperationQueue.swift +++ b/TestFoundation/TestNSOperationQueue.swift @@ -20,8 +20,7 @@ import SwiftXCTest class TestNSOperationQueue : XCTestCase { static var allTests: [(String, (TestNSOperationQueue) -> () throws -> Void)] { return [ - /* uncomment below lines once Dispatch is enabled in Foundation */ - // ("test_OperationPriorities", test_OperationPriorities), + ("test_OperationPriorities", test_OperationPriorities), ("test_OperationCount", test_OperationCount) ] } @@ -31,9 +30,8 @@ class TestNSOperationQueue : XCTestCase { let op1 = BlockOperation(block: { sleep(2) }) queue.addOperation(op1) XCTAssertTrue(queue.operationCount == 1) - /* uncomment below lines once Dispatch is enabled in Foundation */ - //queue.waitUntilAllOperationsAreFinished() - //XCTAssertTrue(queue.operationCount == 0) + queue.waitUntilAllOperationsAreFinished() + XCTAssertTrue(queue.operationCount == 0) } func test_OperationPriorities() {