Replies: 1 comment
-
Hello, The way to run a coroutine would be to use Responsibly.WaitForCoroutine, together with expecting it to finish within some deadline with ExpectWithinSeconds. For async/await code, you can use WaitForTask. It might feel a bit unintuitive to use wait conditions for this at first, but it is require to enforce a timeout on all operations, and provides better composability in the big picture. And sorry for the late response! It seems like I need to tweak my notification settings to get notified on new discussions 🤔 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Salutations,
We're attempting to use the BDD part of the Responsible framework to try to automate acceptance testing in our Unity application. We're running into an issue however, in that we're not sure how to use coroutines or async methods when executing things as part of the Given/When instructions. Is there a part of the documentation that we're missing? Or do you have any suggestions for usage? Is this even possible at this time?
For example, say I have the following coroutines where setup is occuring.
and that I wanted to test them as such:
However, when we execute this, it doesn't appear to actually run the coroutines, as it references 0 frames despite putting check marks next to the Given and When sections:
Any ideas? Thank you for your assistance, we greatly appreciate your product.
Beta Was this translation helpful? Give feedback.
All reactions