From af288ea960dca8517d88a7c8431ff0e16488e8c6 Mon Sep 17 00:00:00 2001 From: Suchit Sahoo Date: Fri, 2 May 2025 14:25:46 -0700 Subject: [PATCH] Fix Flaky Tests Signed-off-by: Suchit Sahoo --- .../opensearch-dashboards/apps/vis_type_table/data.spec.js | 1 + .../opensearch-dashboards/apps/vis_type_table/embed.spec.js | 1 + .../opensearch-dashboards/apps/vis_type_table/options.spec.js | 1 + .../opensearch-dashboards/apps/vis_type_table/split.spec.js | 1 + 4 files changed, 4 insertions(+) diff --git a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/data.spec.js b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/data.spec.js index 5c6264702..710379c5a 100644 --- a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/data.spec.js +++ b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/data.spec.js @@ -192,6 +192,7 @@ describe('table visualization data', () => { timestamp: '2022-08-30T23:20:41.280Z', username: 'missing', }); + cy.forceMergeSegments(); cy.reload(); cy.tbGetTableDataFromVisualization().then((data) => { expect(data).to.deep.eq(['10,001']); diff --git a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/embed.spec.js b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/embed.spec.js index cf96b6079..2ee1e9e11 100644 --- a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/embed.spec.js +++ b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/embed.spec.js @@ -63,6 +63,7 @@ describe('table visualization in embedded mode', () => { cy.deleteIndexPattern(TABLE_INDEX_PATTERN); cy.bulkUploadDocs(TABLE_PATH_INDEX_DATA); cy.importSavedObjects(TABLE_PATH_SO_DATA); + cy.forceMergeSegments(); // Load table visualization cy.visit(`${BASE_PATH}/app/visualize`); cy.get('input[type="search"]').type(`${TABLE_BASIC_VIS_TITLE}{enter}`); diff --git a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/options.spec.js b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/options.spec.js index 2075f3f17..a1c38b356 100644 --- a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/options.spec.js +++ b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/options.spec.js @@ -25,6 +25,7 @@ describe('Table visualization options', () => { cy.deleteIndexPattern(TABLE_INDEX_PATTERN); cy.bulkUploadDocs(TABLE_PATH_INDEX_DATA); cy.importSavedObjects(TABLE_PATH_SO_DATA); + cy.forceMergeSegments(); // Load table visualization cy.visit(`${BASE_PATH}/app/visualize`); cy.get('input[type="search"]').type(`${TABLE_BASIC_VIS_TITLE}{enter}`); diff --git a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/split.spec.js b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/split.spec.js index ec4c10dc8..68dcd383e 100644 --- a/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/split.spec.js +++ b/cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_table/split.spec.js @@ -68,6 +68,7 @@ describe.skip('Split table', () => { cy.deleteIndexPattern(TABLE_INDEX_PATTERN); cy.bulkUploadDocs(TABLE_PATH_INDEX_DATA); cy.importSavedObjects(TABLE_PATH_SO_DATA); + cy.forceMergeSegments(); // Load table visualization cy.visit(`${BASE_PATH}/app/visualize`); cy.get('input[type="search"]').type(`${TABLE_BASIC_VIS_TITLE}{enter}`);