Skip to content

Commit 568e012

Browse files
committed
Reproduce pause/cancel bug when chained with then/success/catch.
1 parent 9438564 commit 568e012

File tree

3 files changed

+403
-55
lines changed

3 files changed

+403
-55
lines changed

SwiftTaskTests/RetainCycleTests.swift

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -90,10 +90,10 @@ class RetainCycleTests: _TestCase
9090

9191
}
9292

93-
self.wait {
94-
XCTAssertNil(self.task)
95-
XCTAssertNil(self.player)
96-
}
93+
self.wait()
94+
95+
XCTAssertNil(self.task)
96+
XCTAssertNil(self.player)
9797
}
9898

9999
func testPlayer_completionAsArgument_configured()
@@ -136,10 +136,10 @@ class RetainCycleTests: _TestCase
136136

137137
}
138138

139-
self.wait {
140-
XCTAssertNil(self.task)
141-
XCTAssertNil(self.player)
142-
}
139+
self.wait()
140+
141+
XCTAssertNil(self.task)
142+
XCTAssertNil(self.player)
143143
}
144144

145145
func testPlayer_completionAsStoredProperty_notConfigured()
@@ -178,10 +178,10 @@ class RetainCycleTests: _TestCase
178178

179179
}
180180

181-
self.wait {
182-
XCTAssertNil(self.task)
183-
XCTAssertNil(self.player)
184-
}
181+
self.wait()
182+
183+
XCTAssertNil(self.task)
184+
XCTAssertNil(self.player)
185185
}
186186

187187
func testPlayer_completionAsStoredProperty_configured()
@@ -222,9 +222,9 @@ class RetainCycleTests: _TestCase
222222

223223
}
224224

225-
self.wait {
226-
XCTAssertNil(self.task)
227-
XCTAssertNil(self.player)
228-
}
225+
self.wait()
226+
227+
XCTAssertNil(self.task)
228+
XCTAssertNil(self.player)
229229
}
230230
}

0 commit comments

Comments
 (0)