mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-05-15 21:05:12 +01:00
Remove Enable Azure synapse link for Cassandra (#1427)
This commit is contained in:
parent
1b5a9b83ff
commit
755b732532
@ -54,6 +54,22 @@ describe("CommandBarComponentButtonFactory tests", () => {
|
|||||||
);
|
);
|
||||||
expect(enableAzureSynapseLinkBtn).toBeUndefined();
|
expect(enableAzureSynapseLinkBtn).toBeUndefined();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it("Button should not be visible for Cassandra API", () => {
|
||||||
|
updateUserContext({
|
||||||
|
databaseAccount: {
|
||||||
|
properties: {
|
||||||
|
capabilities: [{ name: "EnableCassandra" }],
|
||||||
|
},
|
||||||
|
} as DatabaseAccount,
|
||||||
|
});
|
||||||
|
|
||||||
|
const buttons = CommandBarComponentButtonFactory.createStaticCommandBarButtons(mockExplorer, selectedNodeState);
|
||||||
|
const enableAzureSynapseLinkBtn = buttons.find(
|
||||||
|
(button) => button.commandButtonLabel === enableAzureSynapseLinkBtnLabel
|
||||||
|
);
|
||||||
|
expect(enableAzureSynapseLinkBtn).toBeUndefined();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("Enable notebook button", () => {
|
describe("Enable notebook button", () => {
|
||||||
|
@ -51,7 +51,7 @@ export function createStaticCommandBarButtons(
|
|||||||
const buttons: CommandButtonComponentProps[] = [];
|
const buttons: CommandButtonComponentProps[] = [];
|
||||||
|
|
||||||
buttons.push(newCollectionBtn);
|
buttons.push(newCollectionBtn);
|
||||||
if (userContext.apiType !== "Tables") {
|
if (userContext.apiType !== "Tables" && userContext.apiType !== "Cassandra") {
|
||||||
const addSynapseLink = createOpenSynapseLinkDialogButton(container);
|
const addSynapseLink = createOpenSynapseLinkDialogButton(container);
|
||||||
|
|
||||||
if (addSynapseLink) {
|
if (addSynapseLink) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user