You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2023/07/05 18:14:32 UTC

[GitHub] [airflow] potiuk commented on a diff in pull request #32331: Only update crawler tags if present in config dict

potiuk commented on code in PR #32331:
URL: https://github.com/apache/airflow/pull/32331#discussion_r1253466086


##########
tests/providers/amazon/aws/hooks/test_glue_crawler.py:
##########
@@ -160,6 +160,18 @@ def test_remove_all_tags(self, mock_get_conn):
             ResourceArn=self.crawler_arn, TagsToRemove=["test", "bar"]
         )
 
+    @mock_sts
+    @mock.patch.object(GlueCrawlerHook, "get_conn")
+    def test_update_missing_tags(self, mock_get_conn):
+        mock_config_missing_tags = deepcopy(mock_config)
+        mock_config_missing_tags.pop("Tags")
+        mock_get_conn.return_value.get_crawler.return_value = {"Crawler": mock_config_missing_tags}
+
+        assert self.hook.update_crawler(**mock_config_missing_tags) is False

Review Comment:
   yeah. Can you double check it @utkarsharma2 ?



-- 
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: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org