dr.update_state()
    session.flush()
    dr = session.query(DagRun).one()
    assert dr.state == DagRunState.FAILED
@pytest.mark.parametrize(
    "input, expected",
    [
        (["s1 >> w1 >> t1"], {"w1"}),  
        (["s1 >> w1 >> t1", "s1 >> t1"], {"w1"}),  
        (["s1 >> w1"], {"w1"}),  
        (["s1 >> w1 >> t1_"], {"t1_"}),  
        (["s1 >> w1 >> t1_", "s1 >> t1_"], {"t1_"}),  
        (["s1 >> w1 >> t1_ >> w2", "s1 >> t1_"], {"w2"}),  
        (["s1 >> w1 >> t1_ >> w2", "s1 >> t1_"], {"w2"}),  
        (["t1 >> t2"], {"t2"}),  
        (["w1 >> t1_ >> t2"], {"t1_"}),  
    ],
)
def test_tis_considered_for_state(dag_maker, session, input, expected):
    """
    We use a convenience notation to wire up test scenarios:
    t<num> -- teardown task
    t<num>_ -- teardown task with on_failure_fail_dagrun = True
    s<num> -- setup task
    w<num> -- work task (a.k.a. normal task)
    In the test input, each line is a statement. We'll automatically create the tasks and wire them up
    as indicated in the test input.
    """
    @teardown
    def teardown_task():