From 3f4e31885ff043ddbf67f45ecfe89b8857428c5a Mon Sep 17 00:00:00 2001 From: DvvCz <86097860+DvvCz@users.noreply.github.com> Date: Mon, 14 Aug 2023 10:55:52 -0700 Subject: [PATCH] Add test case --- tests/globals/coroutine.luau | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/globals/coroutine.luau b/tests/globals/coroutine.luau index 5780b78..8db0c42 100644 --- a/tests/globals/coroutine.luau +++ b/tests/globals/coroutine.luau @@ -74,3 +74,13 @@ end)() assert(not flag2, "Wait failed while inside wrap (1)") task.wait(0.2) assert(flag2, "Wait failed while inside wrap (2)") + +-- Coroutines should be passed arguments on initial resume + +local co = coroutine.create(function(a, b, c) + assert(a == 1) + assert(b == "Hello, world!") + assert(c == true) +end) + +coroutine.resume(co, 1, "Hello, world!", true)