| ... | ... | @@ -973,10 +973,9 @@ test "Select.cancel with no tasks, no deadlock" { |
| 973 | 973 | } |
| 974 | 974 | |
| 975 | 975 | test "Condition" { |
| 976 | | if (builtin.single_threaded) return error.SkipZigTest; |
| 977 | 976 | const io = testing.io; |
| 978 | 977 | |
| 979 | | const TestContext = struct { |
| 978 | const Context = struct { |
| 980 | 979 | ready: Io.Event = .unset, |
| 981 | 980 | mutex: Io.Mutex = .init, |
| 982 | 981 | cond: Io.Condition = .init, |
| ... | ... | @@ -1001,9 +1000,11 @@ test "Condition" { |
| 1001 | 1000 | } |
| 1002 | 1001 | }; |
| 1003 | 1002 | |
| 1004 | | var ctx: TestContext = .{}; |
| 1003 | var ctx: Context = .{}; |
| 1005 | 1004 | |
| 1006 | | var future = try io.concurrent(TestContext.worker, .{&ctx}); |
| 1005 | var future = io.concurrent(Context.worker, .{&ctx}) catch |err| switch (err) { |
| 1006 | error.ConcurrencyUnavailable => return error.SkipZigTest, |
| 1007 | }; |
| 1007 | 1008 | defer future.cancel(io) catch {}; |
| 1008 | 1009 | |
| 1009 | 1010 | try ctx.ready.wait(io); |