Skip to content

Commit

Permalink
test(cypress): Removed references to menuOptions
Browse files Browse the repository at this point in the history
  • Loading branch information
justin-bits committed Jun 18, 2019
1 parent 9fc43db commit 01afddc
Show file tree
Hide file tree
Showing 6 changed files with 154 additions and 182 deletions.
18 changes: 9 additions & 9 deletions cypress/integration/smoke-tests/status-bar.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ describe('Status bar', function() {
// Test
cy.get(core.statusBar.Scale.BAR).click();
cy.get(core.statusBar.Scale.Menu.PANEL).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.IMPERIAL).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.METRIC).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.NAUTICAL).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.NAUTICAL_MILES_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.MILES_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.YARDS_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.menuOptions.FEET_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.IMPERIAL).should('be.visible');
cy.get(core.statusBar.Scale.Menu.METRIC).should('be.visible');
cy.get(core.statusBar.Scale.Menu.NAUTICAL).should('be.visible');
cy.get(core.statusBar.Scale.Menu.NAUTICAL_MILES_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.MILES_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.YARDS_ONLY).should('be.visible');
cy.get(core.statusBar.Scale.Menu.FEET_ONLY).should('be.visible');

// Clean up
cy.get(core.statusBar.Scale.BAR).click();
Expand All @@ -83,13 +83,13 @@ describe('Status bar', function() {

// Test
cy.get(core.statusBar.Scale.BAR).click();
cy.get(core.statusBar.Scale.Menu.menuOptions.IMPERIAL).click();
cy.get(core.statusBar.Scale.Menu.IMPERIAL).click();
cy.get(core.statusBar.Scale.Menu.PANEL).should('not.be.visible');
cy.get(core.statusBar.Scale.BAR).should('contain', 'mi');

// Clean up
cy.get(core.statusBar.Scale.BAR).click();
cy.get(core.statusBar.Scale.Menu.menuOptions.METRIC).click();
cy.get(core.statusBar.Scale.Menu.METRIC).click();
});

it('Coordinates', function() {
Expand Down
48 changes: 24 additions & 24 deletions cypress/integration/smoke-tests/toolbar-left.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,11 @@ describe('Toolbar left', function() {
// Test
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.addData.Menu.menuOptions.ADD_DATA).should('be.visible');
cy.get(core.Toolbar.addData.Menu.menuOptions.OPEN_FILE_OR_URL).should('be.visible');
cy.get(core.Toolbar.addData.Menu.menuOptions.ADD_CESIUM_ION_ASSET).should('be.visible');
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_WORLD_IMAGERY).should('be.visible');
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_STREET_MAP).should('be.visible');
cy.get(core.Toolbar.addData.Menu.ADD_DATA).should('be.visible');
cy.get(core.Toolbar.addData.Menu.OPEN_FILE_OR_URL).should('be.visible');
cy.get(core.Toolbar.addData.Menu.ADD_CESIUM_ION_ASSET).should('be.visible');
cy.get(core.Toolbar.addData.Menu.RECENT_WORLD_IMAGERY).should('be.visible');
cy.get(core.Toolbar.addData.Menu.RECENT_STREET_MAP).should('be.visible');

// Clean up
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
Expand All @@ -64,7 +64,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.ADD_DATA).click();
cy.get(core.Toolbar.addData.Menu.ADD_DATA).click();
cy.get(dialogs.addDataDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -78,7 +78,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.OPEN_FILE_OR_URL).click();
cy.get(core.Toolbar.addData.Menu.OPEN_FILE_OR_URL).click();
cy.get(imports.importDataDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -92,7 +92,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.ADD_CESIUM_ION_ASSET).click();
cy.get(core.Toolbar.addData.Menu.ADD_CESIUM_ION_ASSET).click();
cy.get(imports.importCesiumIonAssetDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -115,18 +115,18 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_STREET_MAP).click();
cy.get(core.Toolbar.addData.Menu.RECENT_STREET_MAP).click();
cy.get(layers.layersTab.Tree.STREET_MAP_TILES).should('not.exist');
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_WORLD_IMAGERY).click();
cy.get(core.Toolbar.addData.Menu.RECENT_WORLD_IMAGERY).click();
cy.get(layers.layersTab.Tree.WORLD_IMAGERY_TILES).should('not.exist');

// Clean up
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_STREET_MAP).click();
cy.get(core.Toolbar.addData.Menu.RECENT_STREET_MAP).click();
cy.get(layers.layersTab.Tree.STREET_MAP_TILES).should('be.visible');
cy.get(core.Toolbar.addData.Menu.BUTTON).click();
cy.get(core.Toolbar.addData.Menu.menuOptions.RECENT_WORLD_IMAGERY).click();
cy.get(core.Toolbar.addData.Menu.RECENT_WORLD_IMAGERY).click();
cy.get(layers.layersTab.Tree.WORLD_IMAGERY_TILES).should('be.visible');
cy.get(layers.layersTab.Tree.STREET_MAP_TILES)
.find(layers.layersTab.Tree.LAYER_TOGGLE_CHECKBOX)
Expand Down Expand Up @@ -184,13 +184,13 @@ describe('Toolbar left', function() {
// Test
cy.get(core.Toolbar.Drawing.Menu.BUTTON).click();
cy.get(core.Toolbar.Drawing.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.BOX).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.CIRCLE).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.POLYGON).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.LINE).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.CHOOSE_AREA).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.ENTER_COORDINATES).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.menuOptions.WHOLE_WORLD).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.BOX).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.CIRCLE).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.POLYGON).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.LINE).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.CHOOSE_AREA).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.ENTER_COORDINATES).should('be.visible');
cy.get(core.Toolbar.Drawing.Menu.WHOLE_WORLD).should('be.visible');

// Clean up
cy.get(core.Toolbar.Drawing.Menu.BUTTON).click();
Expand All @@ -203,7 +203,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.Drawing.Menu.BUTTON).click();
cy.get(core.Toolbar.Drawing.Menu.menuOptions.CHOOSE_AREA).click();
cy.get(core.Toolbar.Drawing.Menu.CHOOSE_AREA).click();
cy.get(dialogs.chooseAreaDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -217,7 +217,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.Drawing.Menu.BUTTON).click();
cy.get(core.Toolbar.Drawing.Menu.menuOptions.ENTER_COORDINATES).click();
cy.get(core.Toolbar.Drawing.Menu.ENTER_COORDINATES).click();
cy.get(dialogs.enterAreaCoordinatesDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -234,7 +234,7 @@ describe('Toolbar left', function() {

// Test
cy.get(core.Toolbar.Drawing.Menu.BUTTON).click();
cy.get(core.Toolbar.Drawing.Menu.menuOptions.WHOLE_WORLD).click();
cy.get(core.Toolbar.Drawing.Menu.WHOLE_WORLD).click();
cy.get(layers.areasTab.Tree.WHOLE_WORLD_AREA).should('be.visible');

// Clean up
Expand Down Expand Up @@ -278,8 +278,8 @@ describe('Toolbar left', function() {
// Test
cy.get(core.Toolbar.Measure.Menu.BUTTON).click();
cy.get(core.Toolbar.Measure.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.Measure.Menu.menuOptions.MEASURE_GEODESIC).should('be.visible');
cy.get(core.Toolbar.Measure.Menu.menuOptions.MEASURE_RHUMB_LINE).should('be.visible');
cy.get(core.Toolbar.Measure.Menu.MEASURE_GEODESIC).should('be.visible');
cy.get(core.Toolbar.Measure.Menu.MEASURE_RHUMB_LINE).should('be.visible');

// Clean up
cy.get(core.Toolbar.Measure.Menu.BUTTON).click();
Expand Down
46 changes: 23 additions & 23 deletions cypress/integration/smoke-tests/toolbar-right.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ describe('Toolbar right', function() {
// Test
cy.get(core.Toolbar.Save.Menu.BUTTON).click();
cy.get(core.Toolbar.Save.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.Save.Menu.menuOptions.STATE).should('be.visible');
cy.get(core.Toolbar.Save.Menu.menuOptions.SCREENSHOT).should('be.visible');
cy.get(core.Toolbar.Save.Menu.STATE).should('be.visible');
cy.get(core.Toolbar.Save.Menu.SCREENSHOT).should('be.visible');

// Clean up
cy.get(core.Toolbar.Save.Menu.BUTTON).click();
Expand All @@ -31,7 +31,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Save.Menu.BUTTON).click();
cy.get(core.Toolbar.Save.Menu.menuOptions.STATE).click();
cy.get(core.Toolbar.Save.Menu.STATE).click();
cy.get(dialogs.saveStateDialog.DIALOG).should('be.visible');

// Clean up
Expand Down Expand Up @@ -59,9 +59,9 @@ describe('Toolbar right', function() {
// Test
cy.get(core.Toolbar.States.Menu.BUTTON).click();
cy.get(core.Toolbar.States.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.States.Menu.menuOptions.IMPORT_STATE).should('be.visible');
cy.get(core.Toolbar.States.Menu.menuOptions.SAVE_STATE).should('be.visible');
cy.get(core.Toolbar.States.Menu.menuOptions.DISABLE_STATES).should('be.visible');
cy.get(core.Toolbar.States.Menu.IMPORT_STATE).should('be.visible');
cy.get(core.Toolbar.States.Menu.SAVE_STATE).should('be.visible');
cy.get(core.Toolbar.States.Menu.DISABLE_STATES).should('be.visible');

// Clean up
cy.get(core.Toolbar.States.Menu.BUTTON).click();
Expand All @@ -74,7 +74,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.States.Menu.BUTTON).click();
cy.get(core.Toolbar.States.Menu.menuOptions.IMPORT_STATE).click();
cy.get(core.Toolbar.States.Menu.IMPORT_STATE).click();
cy.get(imports.importDataDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -89,7 +89,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.States.Menu.BUTTON).click();
cy.get(core.Toolbar.States.Menu.menuOptions.SAVE_STATE).click();
cy.get(core.Toolbar.States.Menu.SAVE_STATE).click();
cy.get(dialogs.saveStateDialog.DIALOG).should('be.visible');

// Clean up
Expand All @@ -107,7 +107,7 @@ describe('Toolbar right', function() {
cy.get(imports.importStateDialog.DIALOG).should('be.visible');
cy.get(imports.importStateDialog.CLEAR_CHECKBOX).check();
cy.get(imports.importStateDialog.OK_BUTTON).click();
cy.wait(1000);
cy.wait(2000);
cy.get(layers.layersTab.Tree.LAYER_4).should('contain', 'Police Stations Features (3)');
cy.get(layers.layersTab.Tree.LAYER_5).should('contain', 'Fire Hydrants Features (747)');
cy.get(layers.areasTab.TAB).click();
Expand All @@ -118,7 +118,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.States.Menu.BUTTON).click();
cy.get(core.Toolbar.States.Menu.menuOptions.DISABLE_STATES).click();
cy.get(core.Toolbar.States.Menu.DISABLE_STATES).click();
cy.get(layers.Dialog.DIALOG).should('not.contain', 'Fire Hydrants Tiles');
cy.get(layers.Dialog.DIALOG).should('not.contain', 'Police Stations Tiles');
cy.get(layers.Dialog.DIALOG).should('not.contain', 'Fire Hydrants Features');
Expand Down Expand Up @@ -187,13 +187,13 @@ describe('Toolbar right', function() {
// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.PANEL).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.ABOUT).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.CONTROLS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.SHOW_TIPS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.OPENSPHERE_CAPABILITIES).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.VIEW_ALERTS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.VIEW_LOG).should('be.visible');
cy.get(core.Toolbar.Support.Menu.menuOptions.RESET_SETTINGS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.ABOUT).should('be.visible');
cy.get(core.Toolbar.Support.Menu.CONTROLS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.SHOW_TIPS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.OPENSPHERE_CAPABILITIES).should('be.visible');
cy.get(core.Toolbar.Support.Menu.VIEW_ALERTS).should('be.visible');
cy.get(core.Toolbar.Support.Menu.VIEW_LOG).should('be.visible');
cy.get(core.Toolbar.Support.Menu.RESET_SETTINGS).should('be.visible');

// Clean up
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
Expand All @@ -206,7 +206,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.ABOUT).click();
cy.get(core.Toolbar.Support.Menu.ABOUT).click();
cy.get(dialogs.aboutDialog.DIALOG).should('be.visible');
cy.get(dialogs.aboutDialog.DIALOG).should('contain', 'AngularJS');
cy.get(dialogs.aboutDialog.DIALOG).should('contain', 'Cesium');
Expand All @@ -222,7 +222,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.CONTROLS).click();
cy.get(core.Toolbar.Support.Menu.CONTROLS).click();
cy.get(dialogs.controlsDialog.DIALOG).should('be.visible');
cy.get(dialogs.controlsDialog.DIALOG).should('contain', 'General Controls');
cy.get(dialogs.controlsDialog.DIALOG).should('contain', '3D Controls');
Expand All @@ -238,7 +238,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.SHOW_TIPS).click();
cy.get(core.Toolbar.Support.Menu.SHOW_TIPS).click();
cy.get(dialogs.welcomeToOpenSphereDialog.DIALOG).should('be.visible');
cy.get(dialogs.welcomeToOpenSphereDialog.DIALOG)
.should('contain', 'OpenSphere is a map-driven analysis tool');
Expand All @@ -254,7 +254,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.OPENSPHERE_CAPABILITIES).click();
cy.get(core.Toolbar.Support.Menu.OPENSPHERE_CAPABILITIES).click();
cy.get(dialogs.openSphereCapabilitiesDialog.DIALOG).should('be.visible');
cy.get(dialogs.openSphereCapabilitiesDialog.Tree.CAPABILITY_2)
.should('contain', 'Add Data');
Expand All @@ -273,7 +273,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.VIEW_ALERTS).click();
cy.get(core.Toolbar.Support.Menu.VIEW_ALERTS).click();
cy.get(dialogs.alertsDialog.DIALOG).should('be.visible');
cy.get(dialogs.alertsDialog.DIALOG).should('contain', 'There are no alerts to view');

Expand All @@ -298,7 +298,7 @@ describe('Toolbar right', function() {

// Test
cy.get(core.Toolbar.Support.Menu.BUTTON).click();
cy.get(core.Toolbar.Support.Menu.menuOptions.RESET_SETTINGS).click();
cy.get(core.Toolbar.Support.Menu.RESET_SETTINGS).click();
cy.get(dialogs.resetSettingsDialog.DIALOG).should('be.visible');
cy.get(dialogs.resetSettingsDialog.DIALOG)
.should('contain', 'Are you sure you want to clear your settings and reload');
Expand Down
Loading

0 comments on commit 01afddc

Please sign in to comment.