Skip to content

Conversation

lerouxb
Copy link
Contributor

@lerouxb lerouxb commented Sep 22, 2025

COMPASS-9858

In CI the import frequently succeeds before the tests abort the error. By using a larger fixture we can avoid that.

@Copilot Copilot AI review requested due to automatic review settings September 22, 2025 15:18
@lerouxb lerouxb added the no release notes Fix or feature not for release notes label Sep 22, 2025
@lerouxb lerouxb review requested due to automatic review settings September 22, 2025 15:18
@lerouxb lerouxb requested a review from a team as a code owner September 22, 2025 15:18
@lerouxb lerouxb requested a review from nbbeeken September 22, 2025 15:18
@Copilot Copilot AI review requested due to automatic review settings September 22, 2025 16:28
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR addresses a timing issue in end-to-end tests where import operations complete too quickly for abort functionality to be properly tested. The solution replaces smaller test fixtures with larger ones to ensure imports take sufficient time to allow the abort operations to be tested reliably.

  • Updates three test cases to use larger CSV and JSON fixtures (279,712 documents vs 16,116)
  • Modifies the import confirm selector to only target enabled buttons
  • Adds explanatory comments about the fixture size and testing rationale

Reviewed Changes

Copilot reviewed 2 out of 4 changed files in this pull request and generated no comments.

File Description
packages/compass-e2e-tests/tests/collection-import.test.ts Updates three abort import tests to use larger fixtures and adds explanatory comments
packages/compass-e2e-tests/helpers/selectors.ts Refines import confirm selector to target only enabled buttons

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

'[data-testid="import-modal"] [data-testid="analyze-error"]';
export const ImportConfirm =
'[data-testid="import-modal"] [data-testid="import-button"]';
'[data-testid="import-modal"] [data-testid="import-button"][aria-disabled="false"]';
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Realising this was probably the reason behind so many flakes..

@lerouxb lerouxb merged commit d0d7ea8 into main Sep 22, 2025
57 of 59 checks passed
@lerouxb lerouxb deleted the abort-flake branch September 22, 2025 18:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix no release notes Fix or feature not for release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants