From 70c657648f6b4d746b440e8174bd81ad7e530291 Mon Sep 17 00:00:00 2001 From: Matt Gacy Date: Fri, 10 May 2024 10:12:09 -0700 Subject: [PATCH] Fix tests --- Tests/PersistenceTests/PersistenceTests.swift | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Tests/PersistenceTests/PersistenceTests.swift b/Tests/PersistenceTests/PersistenceTests.swift index 701d945..4e7d5bb 100644 --- a/Tests/PersistenceTests/PersistenceTests.swift +++ b/Tests/PersistenceTests/PersistenceTests.swift @@ -16,15 +16,16 @@ final class PersistenceTests: XCTestCase { let string: String var attributes: [String: AttributeValue] { - var values: [CodingKeys: AttributeValue] = [ + let values: [CodingKeys: AttributeValue] = [ .bool: .bool(bool), .string: .s(string) ] - return values.attributeValues() } } + let timeoutInterval: TimeInterval = 0.1 + func testPersistence() async throws { let expected: [String: AttributeValue] = [ "Bool": .bool(true), @@ -43,6 +44,6 @@ final class PersistenceTests: XCTestCase { } try await sut.put(Model(bool: true, string: "string")) - await fulfillment(of: [expectation]) + await fulfillment(of: [expectation], timeout: timeoutInterval) } }