gokulakrishnansvm commented on code in PR #7400:
URL: https://github.com/apache/trafficcontrol/pull/7400#discussion_r1144025942


##########
traffic_ops/testing/api_contract/v4/test_cdns.py:
##########
@@ -0,0 +1,72 @@
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+"""Api Contract Test Case for cdns endpoint."""
+import json
+import logging
+import pytest
+
+# Create and configure logger
+logger = logging.getLogger()
+
+
+@pytest.fixture(name="get_cdn_data")
+def get_cdn_prereq_data() -> dict:
+    """PyTest Fixture to store prereq data for cdns endpoint.
+    :returns cdn_data: Returns prerequisite data for cdns endpoint
+    """
+    # Response keys for cdns endpoint
+    with open("prerequisite_data.json", encoding="utf-8", mode="r") as 
prereq_file:
+        data = json.load(prereq_file)
+    cdn_data = data["cdns"]
+    return cdn_data
+
+
+def test_get_cdn(to_session: object, get_cdn_data: dict, cdn_prereq: list) -> 
None:

Review Comment:
   Changed the type of to_session to TOSession and also added specific types 
for both the fixtures.



-- 
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: issues-unsubscr...@trafficcontrol.apache.org

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

Reply via email to