Skip to content

Commit 346edcb

Browse files
committed
fix dashboards-maps integ tests by adding a visit to base url
Signed-off-by: Fen Qin <mfenqin@amazon.com>
1 parent 0b0d405 commit 346edcb

9 files changed

+19
-1
lines changed

cypress/integration/plugins/custom-import-map-dashboards/0_add_saved_object.js

+3
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Add flights dataset saved object', () => {
1313
before(() => {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();
@@ -26,6 +28,7 @@ describe('Add flights dataset saved object', () => {
2628
cy.contains(
2729
'[Flights] Flights Status on Maps Destination Location'
2830
).click();
31+
cy.wait(1000);
2932
cy.get('[data-test-subj="layerControlPanel"]').should(
3033
'contain',
3134
'Flights On Time'

cypress/integration/plugins/custom-import-map-dashboards/1_import_vector_map_tab.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ const miscUtils = new MiscUtils(cy);
1313

1414
describe('Verify the presence of import custom map tab in region map plugin', () => {
1515
before(() => {
16+
// visit base url
17+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1618
CURRENT_TENANT.newTenant = 'global';
1719
cy.deleteAllIndices();
1820
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/2_opensearchMapLayer.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Default OpenSearch base map layer', () => {
1313
before(() => {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/3_add_saved_object.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Add flights dataset saved object', () => {
1313
before(() => {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/4_documentsLayer.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Documents layer', () => {
1313
before(() => {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/5_add_map_to_dashboard.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Add map to dashboard', () => {
1313
before(() => {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/6_geojson_file_upload.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ const miscUtils = new MiscUtils(cy);
1212

1313
describe('Verify successful custom geojson file upload', () => {
1414
before(() => {
15+
// visit base url
16+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1517
CURRENT_TENANT.newTenant = 'global';
1618
cy.deleteAllIndices();
1719
miscUtils.addSampleData();

cypress/integration/plugins/custom-import-map-dashboards/7_enable_new_home_ui.spec.js

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ const miscUtils = new MiscUtils(cy);
1111

1212
describe('Add flights dataset saved object', function () {
1313
before(function () {
14+
// visit base url
15+
cy.visit(Cypress.config().baseUrl, { timeout: 10000 });
1416
CURRENT_TENANT.newTenant = 'global';
1517
cy.deleteAllIndices();
1618
miscUtils.addSampleData();

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -74,5 +74,6 @@
7474
"optionator": "^0.9.3",
7575
"cross-spawn": "^7.0.5",
7676
"nanoid": "^3.3.8"
77-
}
77+
},
78+
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
7879
}

0 commit comments

Comments
 (0)