diff --git a/packages/compass-e2e-tests/helpers/commands/save-aggregation-pipeline.ts b/packages/compass-e2e-tests/helpers/commands/save-aggregation-pipeline.ts index ac426c8f614..32b681c9cd1 100644 --- a/packages/compass-e2e-tests/helpers/commands/save-aggregation-pipeline.ts +++ b/packages/compass-e2e-tests/helpers/commands/save-aggregation-pipeline.ts @@ -47,4 +47,7 @@ export async function saveAggregationPipeline( const createButton = browser.$(Selectors.SavePipelineModal).$('button=Save'); await createButton.click(); + + // wait for the modal to disappear + await savePipelineModal.waitForDisplayed({ reverse: true }); }