Skip to content

Commit 348e234

Browse files
committed
Update mds_tsvb.spec.js
Signed-off-by: yujin-emma <[email protected]>
1 parent 5c6d666 commit 348e234

File tree

2 files changed

+2
-18
lines changed
  • cypress

2 files changed

+2
-18
lines changed

cypress/integration/core-opensearch-dashboards/opensearch-dashboards/apps/vis_type_tsvb/mds_tsvb.spec.js

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ describe('TSVB Visualization', () => {
4444

4545
if (Cypress.env('DATASOURCE_MANAGEMENT_ENABLED')) {
4646
before(() => {
47+
cy.deleteAllDataSources();
4748
cy.deleteDataSourceIndexNoAuth(TSVB_INDEX_ID);
4849
cy.createDataSourceNoAuth();
4950
cy.bulkUploadDocsToDataSourceNoAuth(TSVB_PATH_INDEX_DATA);
@@ -73,27 +74,10 @@ describe('TSVB Visualization', () => {
7374
});
7475
});
7576
});
76-
} else {
77-
describe('When MDS is disabled', () => {
78-
it('should query from local cluster', () => {
79-
cy.contains('button', 'Panel options').click();
80-
cy.get('input[data-test-subj="metricsIndexPatternInput"]').type(
81-
TSVB_INDEX_ID
82-
);
83-
cy.tsvbSaveVisualization();
84-
// Visualization should be drawn; correct visualizations do not have warning messages
85-
cy.get('canvas').should('exist');
86-
});
87-
});
8877
}
8978

9079
after(() => {
9180
cy.deleteIndex(TSVB_INDEX_ID);
9281
cy.deleteIndexPattern(TSVB_INDEX_PATTERN);
93-
94-
if (Cypress.env('DATASOURCE_MANAGEMENT_ENABLED')) {
95-
cy.deleteDataSourceIndexNoAuth(TSVB_INDEX_ID);
96-
cy.deleteAllDataSources();
97-
}
9882
});
9983
});

cypress/utils/dashboards/vis_type_tsvb/constants.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export const TSVB_PATH_INDEX_DATA = TSVB_PATH_FIXTURE + TSVB_INDEX_DATA;
1313
// Update the constants
1414
export const TSVB_INDEX_START_TIME = 'May 16, 2010 @ 00:00:00.000';
1515
export const TSVB_INDEX_END_TIME = 'May 16, 2024 @ 00:00:00.000';
16-
export const TSVB_INDEX_ID = 'metrics';
16+
export const TSVB_INDEX_ID = 'vis-metrics';
1717
export const TSVB_INDEX_PATTERN = 'index-pattern-vis-metrics';
1818

1919
export const TSVB_VIS_TYPE = 'visualization';

0 commit comments

Comments
 (0)