From 27ce9021d82006d2ad8db78d5e602c5bba80ca1b Mon Sep 17 00:00:00 2001 From: Leif Date: Sun, 19 Mar 2023 11:00:31 -0600 Subject: [PATCH] Update cancel test --- Tests/TaskManagerTests/TaskManagerTests.swift | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Tests/TaskManagerTests/TaskManagerTests.swift b/Tests/TaskManagerTests/TaskManagerTests.swift index 6bf4c3e..cee5230 100644 --- a/Tests/TaskManagerTests/TaskManagerTests.swift +++ b/Tests/TaskManagerTests/TaskManagerTests.swift @@ -1,3 +1,4 @@ +import t import XCTest @testable import TaskManager @@ -31,8 +32,6 @@ final class TaskManagerTests: XCTestCase { taskManager.cancel(key: .loop) - try await taskManager.wait(for: .loop) - - print("Infinite Loop Task was cancelled") + try await t.assertThrows(try await taskManager.wait(for: .loop)) } }