nhuantho commented on code in PR #59873:
URL: https://github.com/apache/airflow/pull/59873#discussion_r2653413419


##########
airflow-core/tests/unit/api_fastapi/core_api/routes/ui/test_connections.py:
##########
@@ -37,6 +45,41 @@ def test_hook_meta_data(self, test_client):
             if hook_data["connection_type"] == "fs":
                 assert hook_data["hook_name"] == "File (path)"
 
+    @pytest.mark.parametrize(
+        ("extra_fields", "expected_response"),
+        [
+            ({"secret_key": "test-secret_key"}, {"secret_key": "***"}),
+            ({"extra_fields": "test-extra_fields"}, {"extra_fields": 
"test-extra_fields"}),

Review Comment:
   @jason810496, yes, I tested it on UI above and ran pytest without 
   ```@field_validator("extra_fields", mode="after")
       @classmethod
       def redact_extra_fields(cls, v: Mapping | None):
           if v is None:
               return None
   
           return redact(v)
   ```
   
   * It failed
   <img width="1632" height="332" alt="image" 
src="https://github.com/user-attachments/assets/d9958166-559f-4a36-b27d-4c02231d2bde";
 />
   



-- 
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