Skip to content

Commit 424a44d

Browse files
committed
added the headers
1 parent f627468 commit 424a44d

File tree

4 files changed

+4
-0
lines changed

4 files changed

+4
-0
lines changed

backend/src/fhir_controller.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ def __init__(
7272
self.authorizer = authorizer
7373

7474
def get_immunization_by_identifier(self, aws_event) -> dict:
75+
# get the imms id by passing the identifier.
7576
if aws_event.get("headers"):
7677
is_imms_batch_app = aws_event["headers"]["SupplierSystem"] == "Imms-Batch-App"
7778
if not is_imms_batch_app:

backend/src/pds_service.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ def __init__(self, authenticator: AppRestrictedAuth, environment):
1313
if environment != "prod" else "https://api.service.nhs.uk/personal-demographics/FHIR/R4/Patient"
1414

1515
def get_patient_details(self, patient_id) -> dict | None:
16+
# made the pds call
1617
access_token = self.authenticator.get_access_token()
1718
request_headers = {
1819
'Authorization': f'Bearer {access_token}',

backend/tests/test_fhir_controller.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ def test_get_imms_by_identifer(self):
9393
self.assertEqual(body["id"], "test")
9494

9595
def test_get_imms_by_identifer_for_batch(self):
96+
# testcases for the batch
9697
"""it should return Immunization Id if it exists"""
9798
# Given
9899
self.service.get_immunization_by_identifier.return_value = {"id": "test", "Version": 1}

backend/tests/test_immunization_post_validator.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ def test_sample_data(self):
7070
self.assertIsNone(self.validator.validate(json_data))
7171

7272
def test_post_validate_and_set_vaccine_type(self):
73+
# prevalidation
7374
"""
7475
Test validate_and_set_validate_and_set_vaccine_type accepts valid values, rejects invalid
7576
values and rejects missing data

0 commit comments

Comments
 (0)