File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ final class ThreadSafetyTests: XCTestCase {
1717
1818 func testLRUCacheConcurrentAccess( ) {
1919 let iterations = 500
20- let cache = LRUCache < Int , Int > ( capacity: UInt ( iterations ) )
20+ let cache = LRUCache < Int , Int > ( capacity: 5 )
2121
2222 DispatchQueue . concurrentPerform ( iterations: iterations) { i in
2323 cache. set ( value: i, forKey: i)
@@ -29,7 +29,7 @@ final class ThreadSafetyTests: XCTestCase {
2929
3030 func testExpiringCacheConcurrentAccess( ) {
3131 let iterations = 200
32- let cache = ExpiringCache < Int , Int > ( duration: . hours ( 1 ) )
32+ let cache = ExpiringCache < Int , Int > ( duration: . seconds ( 1 ) )
3333
3434 DispatchQueue . concurrentPerform ( iterations: iterations) { i in
3535 cache. set ( value: i, forKey: i)
You can’t perform that action at this time.
0 commit comments