Skip to content

Commit 09b8377

Browse files
committed
Fix splunk logging tests
1 parent 2606e31 commit 09b8377

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

lambdas/ack_backend/tests/test_splunk_logging.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,15 +162,15 @@ def test_splunk_logging_missing_data(self):
162162
patch("common.log_decorator.logger") as mock_logger, # noqa: E999
163163
): # noqa: E999
164164
with self.assertRaises(AttributeError):
165-
lambda_handler(event={"Records": [{"body": json.dumps([{"": "456"}])}]}, context={})
165+
lambda_handler(event={"Records": [{"body": json.dumps([{"": "456", "row_id": "test^1"}])}]}, context={})
166166

167167
expected_first_logger_info_data = {**InvalidValues.logging_with_no_values}
168168

169169
expected_first_logger_error_data = self.expected_lambda_handler_logs(
170170
success=False,
171171
number_of_rows=1,
172172
ingestion_complete=False,
173-
diagnostics="list index out of range",
173+
diagnostics="'NoneType' object has no attribute 'replace'",
174174
)
175175

176176
first_logger_info_call_args = json.loads(self.extract_all_call_args_for_logger_info(mock_logger)[0])

lambdas/ack_backend/tests/utils/values_for_ack_backend_tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ class InvalidValues:
263263
"supplier": "unknown",
264264
"file_key": "file_key_missing",
265265
"vaccine_type": "unknown",
266-
"message_id": "unknown",
266+
"message_id": "test^1",
267267
"operation_requested": "unknown",
268268
"time_taken": "1000.0ms",
269269
"local_id": "unknown",

0 commit comments

Comments
 (0)