[SECURITY] Copy saved object flyout should not allow copying into the active space (#116657)
* copy saved object flyout should not allow copying into the active space * stupid me
This commit is contained in:
parent
45476dcbe6
commit
3f91556e67
2 changed files with 2 additions and 3 deletions
|
@ -112,8 +112,7 @@ const setup = async (opts: SetupOpts = {}) => {
|
||||||
return { wrapper, onClose, mockSpacesManager, mockToastNotifications, savedObjectToCopy };
|
return { wrapper, onClose, mockSpacesManager, mockToastNotifications, savedObjectToCopy };
|
||||||
};
|
};
|
||||||
|
|
||||||
// flaky https://github.com/elastic/kibana/issues/96708
|
describe('CopyToSpaceFlyout', () => {
|
||||||
describe.skip('CopyToSpaceFlyout', () => {
|
|
||||||
it('waits for spaces to load', async () => {
|
it('waits for spaces to load', async () => {
|
||||||
const { wrapper } = await setup({ returnBeforeSpacesLoad: true });
|
const { wrapper } = await setup({ returnBeforeSpacesLoad: true });
|
||||||
|
|
||||||
|
|
|
@ -75,7 +75,7 @@ export const CopyToSpaceFlyoutInternal = (props: CopyToSpaceFlyoutProps) => {
|
||||||
isLoading: false,
|
isLoading: false,
|
||||||
spaces: [...spacesMap.values()].filter(
|
spaces: [...spacesMap.values()].filter(
|
||||||
({ isActiveSpace, isAuthorizedForPurpose }) =>
|
({ isActiveSpace, isAuthorizedForPurpose }) =>
|
||||||
isActiveSpace || isAuthorizedForPurpose('copySavedObjectsIntoSpace')
|
!isActiveSpace && isAuthorizedForPurpose('copySavedObjectsIntoSpace')
|
||||||
),
|
),
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue