ashb commented on a change in pull request #7160: [AIRFLOW-1467] Dynamic 
pooling via allowing tasks to use more than one pool slot (depending upon the 
need)
URL: https://github.com/apache/airflow/pull/7160#discussion_r366305613
 
 

 ##########
 File path: tests/ti_deps/deps/test_pool_slots_available_dep.py
 ##########
 @@ -40,22 +40,22 @@ def tearDown(self):
     @patch('airflow.models.Pool.open_slots', return_value=0)
     # pylint: disable=unused-argument
     def test_pooled_task_reached_concurrency(self, mock_open_slots):
-        ti = Mock(pool='test_pool')
+        ti = Mock(pool='test_pool', pool_capacity=1)
         self.assertFalse(PoolSlotsAvailableDep().is_met(ti=ti))
 
     @patch('airflow.models.Pool.open_slots', return_value=1)
     # pylint: disable=unused-argument
     def test_pooled_task_pass(self, mock_open_slots):
-        ti = Mock(pool='test_pool')
+        ti = Mock(pool='test_pool', pool_capacity=1)
 
 Review comment:
   Isn't 1 the default, meaning most of these changes in tests aren't needed?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to