@@ -40,9 +40,12 @@ def create_valid_cloud_event():
4040 return {
4141 'id' : str (uuid4 ()),
4242 'specversion' : '1.0' ,
43- 'source' : '/nhs/england/notify/development/primary/data-plane/ digitalletters/mesh' ,
43+ 'source' : '/nhs/england/notify/development/primary/digitalletters/mesh' ,
4444 'subject' : 'customer/00000000-0000-0000-0000-000000000000/recipient/00000000-0000-0000-0000-000000000000' ,
4545 'type' : 'uk.nhs.notify.digital.letters.mesh.inbox.message.received.v1' ,
46+ 'plane' : 'data' ,
47+ 'dataschemaversion' : '1.0.0' ,
48+ 'datacontenttype' : 'application/json' ,
4649 'time' : '2023-01-01T12:00:00Z' ,
4750 'recordedtime' : '2023-01-01T12:00:00Z' ,
4851 'severitynumber' : 2 ,
@@ -218,9 +221,12 @@ def test_process_sqs_message_success(self, mock_datetime):
218221
219222 # Verify CloudEvent envelope fields
220223 assert published_event ['type' ] == 'uk.nhs.notify.digital.letters.mesh.inbox.message.downloaded.v1'
221- assert published_event ['source' ] == '/nhs/england/notify/development/primary/data-plane/ digitalletters/mesh'
224+ assert published_event ['source' ] == '/nhs/england/notify/development/primary/digitalletters/mesh'
222225 assert published_event ['subject' ] == 'customer/00000000-0000-0000-0000-000000000000/recipient/00000000-0000-0000-0000-000000000000'
223226 assert published_event ['time' ] == '2025-11-19T15:30:45+00:00'
227+ assert published_event ['plane' ] == 'data'
228+ assert published_event ['dataschemaversion' ] == '1.0.0'
229+ assert published_event ['datacontenttype' ] == 'application/json'
224230 assert 'id' in published_event
225231 assert 'tracestate' not in published_event
226232 assert 'partitionkey' not in published_event
@@ -287,9 +293,12 @@ def test_process_sqs_message_invalid_fhir_content(self, mock_datetime):
287293
288294 # Verify CloudEvent envelope fields
289295 assert published_event ['type' ] == 'uk.nhs.notify.digital.letters.mesh.inbox.message.invalid.v1'
290- assert published_event ['source' ] == '/nhs/england/notify/development/primary/data-plane/ digitalletters/mesh'
296+ assert published_event ['source' ] == '/nhs/england/notify/development/primary/digitalletters/mesh'
291297 assert published_event ['subject' ] == 'customer/00000000-0000-0000-0000-000000000000/recipient/00000000-0000-0000-0000-000000000000'
292298 assert published_event ['time' ] == '2025-11-19T15:30:45+00:00'
299+ assert published_event ['plane' ] == 'data'
300+ assert published_event ['dataschemaversion' ] == '1.0.0'
301+ assert published_event ['datacontenttype' ] == 'application/json'
293302 assert 'id' in published_event
294303 assert 'tracestate' not in published_event
295304 assert 'partitionkey' not in published_event
0 commit comments