@@ -25,7 +25,7 @@ class TestOperationQueue : XCTestCase {
25
25
( " test_CurrentQueueWithCustomUnderlyingQueue " , test_CurrentQueueWithCustomUnderlyingQueue) ,
26
26
( " test_CurrentQueueWithUnderlyingQueueResetToNil " , test_CurrentQueueWithUnderlyingQueueResetToNil) ,
27
27
( " test_isSuspended " , test_isSuspended) ,
28
- ( " test_OperationDependencies " , test_OperationDependencies ) ,
28
+ ( " test_OperationDependencyCount " , test_OperationDependencyCount ) ,
29
29
]
30
30
}
31
31
@@ -266,10 +266,8 @@ class TestOperationQueue : XCTestCase {
266
266
waitForExpectations ( timeout: 1 )
267
267
}
268
268
269
- func test_OperationDependencies( ) {
270
- let queue = OperationQueue ( )
269
+ func test_OperationDependencyCount( ) {
271
270
var results = [ Int] ( )
272
- queue. maxConcurrentOperationCount = 1
273
271
let op1 = BlockOperation {
274
272
results. append ( 1 )
275
273
}
@@ -280,10 +278,6 @@ class TestOperationQueue : XCTestCase {
280
278
op2. name = " op2 "
281
279
op1. addDependency ( op2)
282
280
XCTAssert ( op1. dependencies. count == 1 )
283
- queue. addOperation ( op1)
284
- queue. addOperation ( op2)
285
- queue. waitUntilAllOperationsAreFinished ( )
286
- XCTAssertEqual ( results, [ 2 , 1 ] )
287
281
}
288
282
}
289
283
0 commit comments