mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Merge pull request #15403 from davelopez/23.0_fix_create_switch_histories_anonymously
[23.0] Disable create and switch histories anonymously
This commit is contained in:
@@ -56,6 +56,11 @@ describe("History Navigation", () => {
|
||||
provide: { store },
|
||||
});
|
||||
|
||||
const createButton = wrapper.find("*[data-description='create new history']");
|
||||
expect(createButton.attributes().disabled).toBeFalsy();
|
||||
const switchButton = wrapper.find("*[data-description='switch to another history']");
|
||||
expect(switchButton.attributes().disabled).toBeFalsy();
|
||||
|
||||
const dropDown = wrapper.find("*[data-description='history options']");
|
||||
const optionElements = dropDown.findAll("b-dropdown-item-stub");
|
||||
const optionTexts = optionElements.wrappers.map((el) => el.text());
|
||||
@@ -76,8 +81,12 @@ describe("History Navigation", () => {
|
||||
provide: { store },
|
||||
});
|
||||
|
||||
const dropDown = wrapper.find("*[data-description='history options']");
|
||||
const createButton = wrapper.find("*[data-description='create new history']");
|
||||
expect(createButton.attributes().disabled).toBeTruthy();
|
||||
const switchButton = wrapper.find("*[data-description='switch to another history']");
|
||||
expect(switchButton.attributes().disabled).toBeTruthy();
|
||||
|
||||
const dropDown = wrapper.find("*[data-description='history options']");
|
||||
const enabledOptionElements = dropDown.findAll("b-dropdown-item-stub:not([disabled])");
|
||||
const enabledOptionTexts = enabledOptionElements.wrappers.map((el) => el.text());
|
||||
expect(enabledOptionTexts).toStrictEqual(anonymousOptions);
|
||||
|
||||
@@ -12,7 +12,8 @@
|
||||
data-description="create new history"
|
||||
size="sm"
|
||||
variant="link"
|
||||
title="Create new history"
|
||||
:disabled="currentUser.isAnonymous"
|
||||
:title="userTitle('Create new history')"
|
||||
@click="$emit('createNewHistory')">
|
||||
<Icon fixed-width icon="plus" />
|
||||
</b-button>
|
||||
@@ -23,7 +24,8 @@
|
||||
data-description="switch to another history"
|
||||
size="sm"
|
||||
variant="link"
|
||||
title="Switch to history">
|
||||
:disabled="currentUser.isAnonymous"
|
||||
:title="userTitle('Switch to history')">
|
||||
<Icon fixed-width icon="exchange-alt" />
|
||||
</b-button>
|
||||
|
||||
|
||||
@@ -6,15 +6,14 @@ tags:
|
||||
- "UI"
|
||||
- "visualization"
|
||||
|
||||
requirements:
|
||||
- new_history
|
||||
|
||||
steps:
|
||||
- content: "This short tour will walk you through <b>Galaxy's Window Manager</b> feature"
|
||||
|
||||
- element: "#current-history-panel .create-hist-btn"
|
||||
intro: "Before using the Window Manager, we will create a new history for this tour."
|
||||
postclick: true
|
||||
|
||||
- element: "#tool-panel-upload-button"
|
||||
intro: "Now, we will upload some tabular data into our new history."
|
||||
intro: "First, we will upload some tabular data into our new history."
|
||||
postclick: true
|
||||
|
||||
- element: "#btn-new"
|
||||
@@ -78,7 +77,7 @@ steps:
|
||||
|
||||
- element: "#right"
|
||||
intro: "This is your history. It contains our two tables being uploaded."
|
||||
|
||||
|
||||
- component: history_panel.item(hid=1,state=ok).display_button
|
||||
intro: "Clicking the eye-icon usually displays a dataset in the center panel."
|
||||
postclick: true
|
||||
|
||||
Reference in New Issue
Block a user