Skip to content

Fix flaky test due to non-deterministic ordering of audit_events

Tan Le requested to merge 281063-fix-flaky-audit-preloader-test into master

What does this MR do?

The flaky test was due to non-deterministic ordering of DB records.

The tests create 2 audit_events with the same created_at and since we order by createad_at, this sometimes results in the wrong order.

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • [-] Label as security and @ mention @gitlab-com/gl-security/appsec
  • [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • [-] Security reports checked/validated by a reviewer from the AppSec team

Related to #281063 (closed)

Edited by Tan Le

Merge request reports