Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix flaky form feedback test #1620

Merged
merged 2 commits into from
Apr 12, 2021
Merged

Conversation

mantariksh
Copy link
Contributor

Problem

Form feedback unit tests have been flaking for months because of a non-deterministic expect statement. The issue is that form feedback is sorted by creation order when it is retrieved, but the feedback documents in the test are created asynchronously, so sometimes the array of documents is not in the expected order.

Solution

Sort the array of feedback documents before comparing.

karrui
karrui previously approved these changes Apr 12, 2021
Copy link
Contributor

@karrui karrui left a comment

Choose a reason for hiding this comment

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

<

@karrui karrui dismissed their stale review April 12, 2021 03:16

not fully checked logic

@mantariksh mantariksh force-pushed the test/fix-feedback-flake branch from 470efef to c99274b Compare April 12, 2021 03:26
Copy link
Contributor

@karrui karrui left a comment

Choose a reason for hiding this comment

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

lgtm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants