def test_final_reduce(): config = object() assert tasks.final_reduce([True, True], config) == 0 assert tasks.final_reduce([True, False], config) == 1 assert tasks.final_reduce([], config) == 0