diff --git a/test/casperjs/api-tool-tests.js b/test/casperjs/api-tool-tests.js index a0e886b565c..ff7e5c0bf9f 100644 --- a/test/casperjs/api-tool-tests.js +++ b/test/casperjs/api-tool-tests.js @@ -48,7 +48,7 @@ var panelSectionKeys = [ 'id', 'name', 'description', 'version', 'inputs' ], toolInputKeys = [ - 'html', 'label', 'name', 'type' + 'label', 'name', 'type' // there are others, but it's not consistent across all inputs ]; diff --git a/test/casperjs/modules/historyoptions.js b/test/casperjs/modules/historyoptions.js index 5f19a257640..a032634a4c0 100644 --- a/test/casperjs/modules/historyoptions.js +++ b/test/casperjs/modules/historyoptions.js @@ -189,8 +189,8 @@ HistoryOptions.prototype.data = { unhideHiddenDatasets : "Unhide Hidden Datasets", deleteHiddenDatasets : "Delete Hidden Datasets", showStructure : "Show Structure", - exportCitations : "Export Citations", - exportToFile : "Export to File", + exportCitations : "Export Tool Citations", + exportToFile : "Export History to File", deleteHistory : "Delete", //deleteHistoryPermanently : "Delete Permanently", //Other Actions diff --git a/test/casperjs/modules/user.js b/test/casperjs/modules/user.js index f75e3a7f532..c303aff226c 100644 --- a/test/casperjs/modules/user.js +++ b/test/casperjs/modules/user.js @@ -45,7 +45,7 @@ User.prototype._submitRegistration = function _submitRegistration( email, passwo }; spaceghost.openHomePage( function(){ - this.clickLabel( spaceghost.data.labels.masthead.menus.user ); + this.click( xpath( spaceghost.data.selectors.masthead.user ) ) this.clickLabel( spaceghost.data.labels.masthead.userMenu.register ); this.waitForNavigation( 'user/create', function beforeRegister(){ @@ -83,7 +83,7 @@ User.prototype._submitLogin = function _submitLogin( email, password ){ }; spaceghost.openHomePage( function(){ - this.clickLabel( spaceghost.data.labels.masthead.menus.user ); + this.click( xpath( spaceghost.data.selectors.masthead.user ) ) this.clickLabel( spaceghost.data.labels.masthead.userMenu.login ); this.waitForNavigation( 'user/login', function beforeLogin(){ @@ -139,6 +139,7 @@ User.prototype.registerUser = function registerUser( email, password, username ) */ User.prototype.login = function login( email, password ){ var spaceghost = this.spaceghost; + spaceghost.debug( '(' + spaceghost.getCurrentUrl() + ') attempting login with ' + email + ' using password ' + password ); this._submitLogin( email, password ); //spaceghost.withMainPanel( function mainAfterLogin(){ @@ -191,7 +192,8 @@ User.prototype.logout = function logout(){ var spaceghost = this.spaceghost; this.spaceghost.openHomePage( function(){ if( spaceghost.user.loggedInAs() ){ - spaceghost.clickLabel( spaceghost.data.labels.masthead.menus.user ); + this.click( xpath( spaceghost.data.selectors.masthead.user ) ) + //spaceghost.clickLabel( spaceghost.data.labels.masthead.menus.user ); spaceghost.clickLabel( spaceghost.data.labels.masthead.userMenu.logout ); spaceghost.waitForNavigation( 'user/logout', function _toLogoutPage() { spaceghost.clickLabel( 'go to the home page' ); diff --git a/test/casperjs/registration-tests.js b/test/casperjs/registration-tests.js index d8d0671e8b8..3a1c59caad4 100644 --- a/test/casperjs/registration-tests.js +++ b/test/casperjs/registration-tests.js @@ -26,7 +26,7 @@ spaceghost.test.begin( 'Testing registration of new users', 0, function suite( t this.user._submitRegistration( email, password, username, confirm ); }); spaceghost.openHomePage( function(){ - this.clickLabel( 'User' ); + this.click( xpath( spaceghost.data.selectors.masthead.user ) ) var loggedInAs = this.fetchText( xpath( spaceghost.data.selectors.masthead.userMenu.userEmail_xpath ) ); this.test.assert( loggedInAs.indexOf( email ) !== -1, 'found proper email in user menu: ' + loggedInAs ); }); diff --git a/test/casperjs/spaceghost.js b/test/casperjs/spaceghost.js index efaf8671338..b656ea31559 100644 --- a/test/casperjs/spaceghost.js +++ b/test/casperjs/spaceghost.js @@ -1162,7 +1162,7 @@ SpaceGhost.prototype.getUniverseSetting = function getUniverseSetting( iniKey ){ }; SpaceGhost.prototype.waitForMasthead = function wait( then ) { - return this.waitForText( this.data.labels.masthead.menus.user, then ); + return this.waitForText( this.data.labels.masthead.menus.analyze, then ); }; @@ -1193,7 +1193,8 @@ SpaceGhost.prototype.data = { adminLink : '#masthead a[href="/admin/index"]', userMenu : { userEmail_xpath : '//a[contains(text(),"Logged in as")]' - } + }, + user : '//ul[@id="user"]', }, toolMenu : { container : '.toolMenuContainer' @@ -1225,7 +1226,12 @@ SpaceGhost.prototype.data = { labels : { masthead : { menus : { - user : 'User' + analyze: 'Analyze Data', + workflow: 'Workflow', + libraries: 'Shared Data', + visualization: 'Visualization', + help: 'Help', + user : 'User', }, userMenu : { register : 'Register',