'Test that backfill respects ignore_depends_on_past'

def test_backfill_depends_on_past(self):

    dag = self.dagbag.get_dag(u'test_depends_on_past')
    dag.clear()
    run_date = (DEFAULT_DATE + datetime.timedelta(days=5))
    self.assertRaisesRegexp(AirflowException, u'BackfillJob    is    deadlocked', BackfillJob(dag=dag, start_date=run_date, end_date=run_date).run)
    BackfillJob(dag=dag, start_date=run_date, end_date=run_date, ignore_first_depends_on_past=True).run()
    ti = TI(dag.tasks[0], run_date)
    ti.refresh_from_db()
    self.assertEquals(ti.state, State.SUCCESS)
