dima-asana commented on a change in pull request #4010: [AIRFLOW-1837] Respect 
task start_date when different from dag's
URL: https://github.com/apache/incubator-airflow/pull/4010#discussion_r223922901
 
 

 ##########
 File path: tests/www_rbac/test_views.py
 ##########
 @@ -267,8 +267,8 @@ def test_mount(self):
 
 
 class TestAirflowBaseViews(TestBase):
-    default_date = timezone.datetime(2018, 3, 1)
-    run_id = "test_{}".format(models.DagRun.id_for_date(default_date))
+    EXAMPLE_DAG_DEFAULT_DATE = dates.days_ago(2)
 
 Review comment:
   Yes, it's needed.
   
   This date gets called in e.g. 
https://github.com/apache/incubator-airflow/pull/4010/files/49ca7ad528cec88503bd011ca0c71218b168a05c#diff-8919d07682d67296863b9c62a96af963L298
   
   That line creates a DagRun for previously 2018-03-01.
   The example DAG that this test is testing has a start date of 2 day ago, 
e.g. 2018-10-07.
   
   Before this change, task instances would get created regardless of the DAG 
start date.  After this change, only task instances after the DAG start date 
get created.  So if I kept the DagRun for 2018-03-01, the instances being 
tested wouldn't get created.
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to