dstandish commented on code in PR #38788:
URL: https://github.com/apache/airflow/pull/38788#discussion_r1594471224


##########
tests/models/test_taskinstance.py:
##########
@@ -1123,54 +1129,54 @@ def test_depends_on_past(self, dag_maker):
             #
             # Tests for all_success
             #
-            ["all_success", 0, _UpstreamTIStates(5, 0, 0, 0, 0, 5, 0, 0), 
True, None, True],
-            ["all_success", 0, _UpstreamTIStates(2, 0, 0, 0, 0, 2, 0, 0), 
True, None, False],
-            ["all_success", 0, _UpstreamTIStates(2, 0, 1, 0, 0, 3, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["all_success", 0, _UpstreamTIStates(2, 1, 0, 0, 0, 3, 0, 0), 
True, State.SKIPPED, False],
+            ["all_success", 0, [SUCCESS, SUCCESS, SUCCESS, SUCCESS, SUCCESS], 
True, None, True],
+            ["all_success", 0, [SUCCESS, SUCCESS, None, None, None], True, 
None, False],
+            ["all_success", 0, [SUCCESS, SUCCESS, FAILED, None, None], True, 
State.UPSTREAM_FAILED, False],
+            ["all_success", 0, [SUCCESS, SUCCESS, SKIPPED, None, None], True, 
SKIPPED, False],
             #
             # Tests for one_success
             #
-            ["one_success", 0, _UpstreamTIStates(5, 0, 0, 0, 0, 5, 0, 0), 
True, None, True],
-            ["one_success", 0, _UpstreamTIStates(2, 0, 0, 0, 0, 2, 0, 0), 
True, None, True],
-            ["one_success", 0, _UpstreamTIStates(2, 0, 1, 0, 0, 3, 0, 0), 
True, None, True],
-            ["one_success", 0, _UpstreamTIStates(2, 1, 0, 0, 0, 3, 0, 0), 
True, None, True],
-            ["one_success", 0, _UpstreamTIStates(0, 5, 0, 0, 0, 5, 0, 0), 
True, State.SKIPPED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 4, 1, 0, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 3, 1, 1, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 4, 0, 1, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 0, 5, 0, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 0, 4, 1, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
-            ["one_success", 0, _UpstreamTIStates(0, 0, 0, 5, 0, 5, 0, 0), 
True, State.UPSTREAM_FAILED, False],
+            ["one_success", 0, [SUCCESS, SUCCESS, SUCCESS, SUCCESS, SUCCESS], 
True, None, True],

Review Comment:
   i'm not a super huge fan of the scrutability of the "old" way, but it's hard 
to see how the new way tests the same thing.  like i said below, i think best 
to separate test change from code+test change



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to