Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,9 @@ def receive_dlq():


@markers.aws.validated
@pytest.mark.skip(
reason="Flaky as an SQS queue will not always return messages in a ReceiveMessages call."
)
def test_report_batch_item_failures(
create_lambda_function,
sqs_create_queue,
Expand Down Expand Up @@ -538,6 +541,7 @@ def test_report_batch_item_failures(
# now wait for the first invocation result which is expected to have processed message 1 we wait half the retry
# interval to wait long enough for the message to appear, but short enough to check that the DLQ is empty after
# the first attempt.
# FIXME: We cannot assume that the queue will always return a message in the given time-interval.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe, we can use the collect sqs messages fixture doing retries. Good catch 👍

first_invocation = aws_client.sqs.receive_message(
QueueUrl=destination_url, WaitTimeSeconds=int(retry_timeout / 2), MaxNumberOfMessages=1
)
Expand Down
Loading