Skip to content

Commit 1929a34

Browse files
Remove FXIOS-12339 [Unit tests] Skipping test testRandomThreading (backport #26884) (#26904)
Remove FXIOS-12339 [Unit tests] Skipping test testRandomThreading (#26884) Skipping test (cherry picked from commit 8a29dcd) Co-authored-by: lmarceau <[email protected]>
1 parent 58bb6d9 commit 1929a34

File tree

1 file changed

+25
-24
lines changed

1 file changed

+25
-24
lines changed

firefox-ios/firefox-ios-tests/Tests/ClientTests/TestHistory.swift

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -238,30 +238,31 @@ class TestHistory: XCTestCase {
238238

239239
// Fuzzing tests. These fire random insert/query/clear commands into the history database from threads.
240240
// The don't check the results. Just look for crashes.
241-
func testRandomThreading() {
242-
let queue = DispatchQueue(
243-
label: "My Queue",
244-
qos: DispatchQoS.default,
245-
attributes: DispatchQueue.Attributes.concurrent,
246-
autoreleaseFrequency: DispatchQueue.AutoreleaseFrequency.inherit,
247-
target: nil
248-
)
249-
var counter = 0
250-
251-
let expectation = self.expectation(description: "Wait for history")
252-
for _ in 0..<self.numThreads {
253-
var places = profile.places
254-
self.runRandom(&places, queue: queue, completion: { () in
255-
counter += 1
256-
if counter == self.numThreads {
257-
self.profile.places.deleteEverythingHistory().uponQueue(.global()) { result in
258-
XCTAssertTrue(result.isSuccess, "History cleared.")
259-
expectation .fulfill()
260-
}
261-
}
262-
})
263-
}
264-
self.waitForExpectations(timeout: 10, handler: nil)
241+
func testRandomThreading() throws {
242+
throw XCTSkip("Skipping this test since https://mozilla-hub.atlassian.net/browse/FXIOS-12339")
243+
// let queue = DispatchQueue(
244+
// label: "My Queue",
245+
// qos: DispatchQoS.default,
246+
// attributes: DispatchQueue.Attributes.concurrent,
247+
// autoreleaseFrequency: DispatchQueue.AutoreleaseFrequency.inherit,
248+
// target: nil
249+
// )
250+
// var counter = 0
251+
//
252+
// let expectation = self.expectation(description: "Wait for history")
253+
// for _ in 0..<self.numThreads {
254+
// var places = profile.places
255+
// self.runRandom(&places, queue: queue, completion: { () in
256+
// counter += 1
257+
// if counter == self.numThreads {
258+
// self.profile.places.deleteEverythingHistory().uponQueue(.global()) { result in
259+
// XCTAssertTrue(result.isSuccess, "History cleared.")
260+
// expectation .fulfill()
261+
// }
262+
// }
263+
// })
264+
// }
265+
// self.waitForExpectations(timeout: 10, handler: nil)
265266
}
266267

267268
// Same as testRandomThreading, but uses one history connection for all threads

0 commit comments

Comments
 (0)