Skip to content

Commit 983eb47

Browse files
committed
fix: resolved inconsistency with active and inactive
1 parent eb3fd35 commit 983eb47

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

postman/Validate_Relationship_Service_Sandbox.postman_collection.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1693,7 +1693,7 @@
16931693
"response": []
16941694
},
16951695
{
1696-
"name": "Filtered proxy relationships by 'proposed' and 'inactive' staus",
1696+
"name": "Filtered proxy relationships by 'proposed' and 'active' staus",
16971697
"event": [
16981698
{
16991699
"listen": "test",
@@ -1977,7 +1977,7 @@
19771977
"method": "GET",
19781978
"header": [],
19791979
"url": {
1980-
"raw": "{{api_base_url}}/Consent?performer:identifier=9000000017&status=proposed,inactive",
1980+
"raw": "{{api_base_url}}/Consent?performer:identifier=9000000017&status=proposed,active",
19811981
"host": [
19821982
"{{api_base_url}}"
19831983
],
@@ -1991,7 +1991,7 @@
19911991
},
19921992
{
19931993
"key": "status",
1994-
"value": "proposed,inactive"
1994+
"value": "proposed,active"
19951995
}
19961996
]
19971997
}

sandbox/api/utils.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -238,15 +238,15 @@ def check_for_consent_filtering_params(
238238
status: str,
239239
status_active_response_yaml: str,
240240
status_inactive_response_yaml: str,
241-
status_proposed_and_inactive_response_yaml: str,
241+
status_proposed_and_active_response_yaml: str,
242242
) -> Response:
243243
"""Checks the GET consent request status params and provides related response
244244
245245
Args:
246246
status (str): The status parameter supplied to the request
247247
status_active_response_yaml (str): The file to return when status param matches with 'active'
248248
status_inactive_response_yaml (str): The response to return when status param matches with 'inactive'
249-
status_proposed_and_inactive_response_yaml (str): The file to return when status param matches with 'proposed,inactive'
249+
status_proposed_and_active_response_yaml (str): The file to return when status param matches with 'proposed,inactive'
250250
251251
Returns:
252252
response: Resultant Response object based on input.
@@ -255,9 +255,9 @@ def check_for_consent_filtering_params(
255255
return generate_response_from_example(status_active_response_yaml, 200)
256256
elif status == "inactive":
257257
return generate_response_from_example(status_inactive_response_yaml, 200)
258-
elif status == "proposed,inactive" or status == "inactive,proposed":
258+
elif status == "proposed,active" or status == "active,proposed":
259259
return generate_response_from_example(
260-
status_proposed_and_inactive_response_yaml, 200
260+
status_proposed_and_active_response_yaml, 200
261261
)
262262
else:
263263
return generate_response_from_example(CONSENT__STATUS_PARAM_INVALID, 400)

0 commit comments

Comments
 (0)