def test_input_dag_linear(self): # A # / \ # B C # / # D couler.dag( [ [lambda: job_a(message="A")], [ lambda: job_a(message="A"), lambda: job_b(message="B"), ], # A -> B [ lambda: job_a(message="A"), lambda: job_c(message="C"), ], # A -> C [ lambda: job_b(message="B"), lambda: job_d(message="D"), ], # B -> D ] ) self.check_argo_yaml("dag_golden_1.yaml")
def diamond(): couler.dag([ [lambda: job_a(message="A")], [lambda: job_a(message="A"), lambda: job_b(message="B")], # A -> B [lambda: job_a(message="A"), lambda: job_c(message="C")], # A -> C [lambda: job_b(message="B"), lambda: job_d(message="D")], # B -> D [lambda: job_c(message="C"), lambda: job_d(message="D")], # C -> D ])
def diamond(): couler.dag([ [lambda: job(name="A")], [lambda: job(name="A"), lambda: job(name="B")], # A -> B [lambda: job(name="A"), lambda: job(name="C")], # A -> C [lambda: job(name="B"), lambda: job(name="D")], # B -> D [lambda: job(name="C"), lambda: job(name="D")], # C -> D ])