I saw a failed test earlier that would have been fixed by a switch to wait_for_and_click in workflow_editor_click_options. This makes that switch and moves some of these workflow editor helper functions into navigates_galaxy.py for reuse by other test cases and by library users.
- set_tags() appeared in both published and saved history tests, refactored into navigates_galaxy with function name history_panel_add_tags
- is_displayed() appeared in both published and saved history tests, refactored into has_driver as selector_is_displayed
- Introduced history_panel_rename to reduce duplication across history panel tests and newer published and saved history tests.
- Removed custom history click option helper in saved and published history tests and just used the variant in navigates_galaxy.
- use wait_for_and_click a couple more places...
- Be sure when sharing a history with a user we wait to actually see that user's e-mail address appear in the history's sharing list after submission.
- Print something for the failed history sharing assertions (I'm pretty sure they are 403 errors because some aspect of the sharing or login didn't work - but might as well verify).
Locally this never happens, but remotely sometimes when sorting by owner the histories are sorted by owner but not in the same order as the test was asserting. I would assume this is likely a postgres vs. sqlite difference - perhaps the former doesn't sort the rows by the order they were created within equal sort classifications (i.e. same owner) but the latter does. I've fixed this - the test should not have been asserting such a strong condition I don't think.
I switched to randomly generated usernames without actually ensure the random usernames would be generated in the same lexiographic order - that wasn't super bright of me. That sort by owner test should pass as frequently as the other tests in that test case class now.
There are a few different transiently failing tests on Jenkins that seem to fail because the test thinks Galaxy is logged in but it is not. So now after we click the login button in Selenium - we will wait for to see the "Register or Login" button turn into the "User" button.
This is a similar problem and fix to what was done in #4562 - which seemed to help.
The the [latest Selenium test execution](https://jenkins.galaxyproject.org/job/selenium/212/testReport/) most of the published histories tests failed. It looks like this is because of the three histories that were supposed to be published, only 2 were actually published. My best guess for what happeend was that the click of the button to publish the history occurred but the next Selenium command happened so quickly that the page had not gotten a chance to respond to the click. This tweaked approach to publishing histories ensures we stay on the page until the "unpublish" link appears - this will either fix the problem or rule this theory out as the explanation.
- Fix rename test for recent change to using alert.
- Test basic adding a tag.
- Outline of a test for downloading workflows.
- Add test for publishing display on index.
- Add test for using the search box on the workflow index page.
This test went from transiently broken to always broken during this release cycle. This PR makes two changes to try to fix both of those conditions. It correct the frame and button Selector for the new workflow run UX for the newer error and this allows explicitly refreshing the browser when waiting for datasets to appear to deal with the transient problems.
This time for the workflow upgrade message test, mirrors the fix in #4524 - the content we are searching for in on this page is no longer in the iframe.
Something releated to AMD broke our way of injecting Sizzle into Galaxy for Selenium tests. This is a much better way that seems to work - just use jQuery ($) as Sizzle if it is available. Avoids an external dependency and another page fetch per test as well as fixing the problem.
Add a test case that just tests the sizzle stuff works on its own. It will be a clear indiciation what is broken if there are related regressions in the future.
- Wait for elements to be clickable before clicking them.
- Allow individual tests to be run on their own and out of order.
- Use randomly generated emails - the tests still can't really be applied to an external Galaxy test server but this gets us closer.