Hi, I’m trying to write a unit test for a workflow...
# ask-the-community
n
Hi, I’m trying to write a unit test for a workflow that contains a
map_task
. This map_task has the
min_success_ratio=0.5
. I’ve tested the workflow in our dev cluster and it seems to work as I would expect. If enough tasks pass the
map_task
succeeds and the failed tasks are returned as empty. However in unit testing it appears to ignore the
min_success_ratio
and if any task fails it immediately exits with an exception. Here’s a small test to illustrate the issue
y
would you mind filing an issue for this? it’s not supported at the moment. i don’t know if this is super high priority for us though - how badly do you need this?
i think the point of the failure ratio is more to account for failures on a live backend. with the understanding that local execution should pretty much always work
n
Thanks, it’s not critical, but happy to file an issue I was trying to write a unit test for the workflow to ensure we had setup the map task as desired
I didn’t realize map_task called a different execute function for local vs remote execution