Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix more CI issues
Browse files Browse the repository at this point in the history
machadoum committed Oct 15, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent cc03022 commit bbbc7e2
Showing 3 changed files with 0 additions and 35 deletions.
1 change: 0 additions & 1 deletion packages/serverless/settings/security_project/index.ts
Original file line number Diff line number Diff line change
@@ -23,5 +23,4 @@ export const SECURITY_PROJECT_SETTINGS = [
settings.SECURITY_SOLUTION_NEWS_FEED_URL_ID,
settings.SECURITY_SOLUTION_ENABLE_NEWS_FEED_ID,
settings.SECURITY_SOLUTION_DEFAULT_ALERT_TAGS_KEY,
settings.SECURITY_SOLUTION_ENABLE_ASSET_CRITICALITY_SETTING,
];
Original file line number Diff line number Diff line change
@@ -60,15 +60,6 @@ describe('useAssetCriticality', () => {

expect(mockFetchAssetCriticalityPrivileges).toHaveBeenCalled();
});

it('does not call privileges API when UI Settings is disabled', async () => {
mockUseHasSecurityCapability.mockReturnValue(true);
mockUseUiSettings.mockReturnValue([false]);

await renderQuery(() => useAssetCriticalityPrivileges('test_entity_name'), 'isSuccess');

expect(mockFetchAssetCriticalityPrivileges).not.toHaveBeenCalled();
});
});

describe('useAssetCriticalityData', () => {
Original file line number Diff line number Diff line change
@@ -180,31 +180,6 @@ describe('Hosts Table', () => {
expect(queryByTestId('tableHeaderCell_node.criticality_5')).toBeInTheDocument();
});

test('it does not render "Asset Criticality" column when Asset Criticality is not enabled in Kibana settings', () => {
mockUseMlCapabilities.mockReturnValue({ isPlatinumOrTrialLicense: true });
mockUseHasSecurityCapability.mockReturnValue(true);
mockUseUiSetting.mockReturnValue([false]);

const { queryByTestId } = render(
<TestProviders store={store}>
<HostsTable
id="hostsQuery"
isInspect={false}
loading={false}
data={mockData}
totalCount={0}
fakeTotalCount={-1}
setQuerySkip={jest.fn()}
showMorePagesIndicator={false}
loadPage={loadPage}
type={hostsModel.HostsType.page}
/>
</TestProviders>
);

expect(queryByTestId('tableHeaderCell_node.criticality_5')).not.toBeInTheDocument();
});

describe('Sorting on Table', () => {
let wrapper: ReturnType<typeof mount>;

0 comments on commit bbbc7e2

Please sign in to comment.