mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-19 11:01:15 +00:00
fix(editor): Hide sso auth protocol selection if no license available (#18655)
This commit is contained in:
committed by
GitHub
parent
9e420d15c1
commit
8b4e8f347f
@@ -80,7 +80,9 @@ describe('SettingsSso View', () => {
|
|||||||
|
|
||||||
const pageRedirectionHelper = usePageRedirectionHelper();
|
const pageRedirectionHelper = usePageRedirectionHelper();
|
||||||
|
|
||||||
const { getByTestId } = renderView();
|
const { getByTestId, queryByTestId } = renderView();
|
||||||
|
|
||||||
|
expect(queryByTestId('sso-auth-protocol-select')).not.toBeInTheDocument();
|
||||||
|
|
||||||
const actionBox = getByTestId('sso-content-unlicensed');
|
const actionBox = getByTestId('sso-content-unlicensed');
|
||||||
expect(actionBox).toBeInTheDocument();
|
expect(actionBox).toBeInTheDocument();
|
||||||
@@ -95,7 +97,10 @@ describe('SettingsSso View', () => {
|
|||||||
|
|
||||||
ssoStore.getSamlConfig.mockResolvedValue(samlConfig);
|
ssoStore.getSamlConfig.mockResolvedValue(samlConfig);
|
||||||
|
|
||||||
const { getAllByTestId } = renderView();
|
const { getAllByTestId, getByTestId } = renderView();
|
||||||
|
|
||||||
|
const authProtocolSelect = getByTestId('sso-auth-protocol-select');
|
||||||
|
expect(authProtocolSelect).toBeInTheDocument();
|
||||||
|
|
||||||
expect(ssoStore.getSamlConfig).toHaveBeenCalledTimes(1);
|
expect(ssoStore.getSamlConfig).toHaveBeenCalledTimes(1);
|
||||||
|
|
||||||
|
|||||||
@@ -310,7 +310,11 @@ async function onOidcSettingsSave() {
|
|||||||
{{ i18n.baseText('settings.sso.info.link') }}
|
{{ i18n.baseText('settings.sso.info.link') }}
|
||||||
</a>
|
</a>
|
||||||
</n8n-info-tip>
|
</n8n-info-tip>
|
||||||
<div :class="$style.group">
|
<div
|
||||||
|
v-if="ssoStore.isEnterpriseSamlEnabled || ssoStore.isEnterpriseOidcEnabled"
|
||||||
|
data-test-id="sso-auth-protocol-select"
|
||||||
|
:class="$style.group"
|
||||||
|
>
|
||||||
<label>Select Authentication Protocol</label>
|
<label>Select Authentication Protocol</label>
|
||||||
<div>
|
<div>
|
||||||
<N8nSelect
|
<N8nSelect
|
||||||
|
|||||||
Reference in New Issue
Block a user