pankajastro commented on code in PR #31009:
URL: https://github.com/apache/airflow/pull/31009#discussion_r1183339652
##########
tests/providers/microsoft/azure/sensors/test_wasb.py:
##########
@@ -128,9 +128,17 @@ def create_context(self, task, dag=None):
deferrable=True,
)
- def test_wasb_blob_sensor_async(self):
+ @mock.patch("airflow.providers.microsoft.azure.sensors.wasb.WasbHook")
+
@mock.patch("airflow.providers.microsoft.azure.sensors.wasb.WasbBlobSensor.defer")
+ def test_wasb_blob_sensor_finish_before_deferred(self, mock_defer,
mock_hook):
+ mock_hook.return_value.check_for_blob.return_value = True
+ self.SENSOR.execute(mock.MagicMock())
+ assert not mock_defer.called
Review Comment:
should we use `mock_defer.assert_not_called()` instead?
--
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]