shubhamraj-git commented on code in PR #46986:
URL: https://github.com/apache/airflow/pull/46986#discussion_r1968243772


##########
tests/api_fastapi/core_api/routes/public/test_pools.py:
##########
@@ -143,83 +143,57 @@ class TestPatchPool(TestPoolsEndpoint):
             (
                 Pool.DEFAULT_POOL_NAME,
                 {},
-                {},
+                {"pool": Pool.DEFAULT_POOL_NAME},
                 400,
                 {"detail": "Only slots and included_deferred can be modified 
on Default Pool"},
             ),
             (
                 Pool.DEFAULT_POOL_NAME,
                 {"update_mask": ["description"]},
-                {},
+                {"pool": Pool.DEFAULT_POOL_NAME},
                 400,
                 {"detail": "Only slots and included_deferred can be modified 
on Default Pool"},
             ),
             (
                 "unknown_pool",
                 {},
-                {},
+                {"pool": "unknown_pool"},
                 404,
                 {"detail": "The Pool with name: `unknown_pool` was not found"},
             ),
             (
                 POOL1_NAME,
                 {},
-                {},
+                {"pool": POOL1_NAME},
                 422,
                 {
                     "detail": [
                         {
-                            "input": {},
-                            "loc": ["pool"],
-                            "msg": "Field required",
-                            "type": "missing",
-                        },
-                        {
-                            "input": {},
+                            "input": {"pool": POOL1_NAME},
                             "loc": ["slots"],
                             "msg": "Field required",
                             "type": "missing",
                         },
                         {
-                            "input": {},
+                            "input": {"pool": POOL1_NAME},
                             "loc": ["description"],
                             "msg": "Field required",
                             "type": "missing",
                         },
                         {
-                            "input": {},
+                            "input": {"pool": POOL1_NAME},
                             "loc": ["include_deferred"],
                             "msg": "Field required",
                             "type": "missing",
                         },
                     ],
                 },
             ),
-            # Success
-            # Partial body
-            (
-                POOL1_NAME,
-                {"update_mask": ["name"]},
-                {"slots": 150, "name": "pool_1_updated"},
-                200,
-                {
-                    "deferred_slots": 0,
-                    "description": None,
-                    "include_deferred": True,
-                    "name": "pool_1_updated",
-                    "occupied_slots": 0,
-                    "open_slots": 3,
-                    "queued_slots": 0,
-                    "running_slots": 0,
-                    "scheduled_slots": 0,
-                    "slots": 3,
-                },
-            ),
             # Partial body on default_pool
             (
                 Pool.DEFAULT_POOL_NAME,
                 {"update_mask": ["slots"]},
-                {"slots": 150},
+                {"pool": Pool.DEFAULT_POOL_NAME, "slots": 150},

Review Comment:
   Sure



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