Skip to content

Commit fdecf88

Browse files
committed
init: unit test fix II
1 parent 72206a7 commit fdecf88

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ack_backend/tests/test_splunk_logging.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,9 @@ def extract_all_call_args_for_logger_error(self, mock_logger):
8787

8888
def expected_lambda_handler_logs(self, success: bool, number_of_rows, diagnostics=None):
8989
"""Returns the expected logs for the lambda handler function."""
90-
# Mocking of timings is such that the time taken is 2 seconds for each row, plus 1 second for the handler
91-
time_taken = f"{number_of_rows * 2 + 1}.0s"
90+
# Mocking of timings is such that the time taken is 2 seconds for each row,
91+
# plus 2 seconds for the handler if it succeeds (i.e. it calls update_ack_file) or 1 second if it doesn't
92+
time_taken = f"{number_of_rows * 2 + 2}.0s" if success else f"{number_of_rows * 2 + 1}.0s"
9293
base_log = (
9394
ValidValues.lambda_handler_success_expected_log
9495
if success

0 commit comments

Comments
 (0)