In my unit tests, I want to assert that workflow.Sleep() was called. How do I do this?
Uber Cadence:如何断言对工作流的调用(Sleep()?)?
- 写回答
- 好问题 0 提建议
- 关注问题
- 邀请回答
-
1条回答 默认 最新
doxp30826 2019-04-25 01:29关注It's possible to access the emulated time using the
TestWorkflowEnvironment.Now()function. For example:before := testenv.Now() testenv.ExecuteWorkflow(...) after := testenv.Now()Then assert on the change between
beforeandafter.本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报