Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ci #6

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions packages/kbn-management/settings/setting_ids/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,6 @@ export const SECURITY_SOLUTION_SHOW_RELATED_INTEGRATIONS_ID =
'securitySolution:showRelatedIntegrations';
export const SECURITY_SOLUTION_DEFAULT_ALERT_TAGS_KEY = 'securitySolution:alertTags' as const;
/** This Kibana Advanced Setting allows users to enable/disable the Asset Criticality feature */
export const SECURITY_SOLUTION_ENABLE_ASSET_CRITICALITY_SETTING =
'securitySolution:enableAssetCriticality' as const;
export const SECURITY_SOLUTION_ENABLE_VISUALIZATIONS_IN_FLYOUT_SETTING =
'securitySolution:enableVisualizationsInFlyout' as const;

Expand Down
1 change: 0 additions & 1 deletion packages/serverless/settings/security_project/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Up @@ -118,10 +118,6 @@ export const stackManagementSchema: MakeSchemaFrom<UsageStats> = {
type: 'boolean',
_meta: { description: 'Non-default value of setting.' },
},
'securitySolution:enableAssetCriticality': {
type: 'boolean',
_meta: { description: 'Non-default value of setting.' },
},
'securitySolution:excludeColdAndFrozenTiersInAnalyzer': {
type: 'boolean',
_meta: { description: 'Non-default value of setting.' },
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ export interface UsageStats {
'securitySolution:defaultAnomalyScore': number;
'securitySolution:refreshIntervalDefaults': string;
'securitySolution:enableNewsFeed': boolean;
'securitySolution:enableAssetCriticality': boolean;
'securitySolution:excludeColdAndFrozenTiersInAnalyzer': boolean;
'securitySolution:enableCcsWarning': boolean;
'securitySolution:enableVisualizationsInFlyout': boolean;
Expand Down
10 changes: 2 additions & 8 deletions src/plugins/telemetry/schema/oss_plugins.json
Original file line number Diff line number Diff line change
Expand Up @@ -10032,12 +10032,6 @@
"description": "Non-default value of setting."
}
},
"securitySolution:enableAssetCriticality": {
"type": "boolean",
"_meta": {
"description": "Non-default value of setting."
}
},
"securitySolution:excludeColdAndFrozenTiersInAnalyzer": {
"type": "boolean",
"_meta": {
Expand All @@ -10050,7 +10044,7 @@
"description": "Non-default value of setting."
}
},
"securitySolution:enableVisualizationsInFlyout":{
"securitySolution:enableVisualizationsInFlyout": {
"type": "boolean",
"_meta": {
"description": "Non-default value of setting."
Expand Down Expand Up @@ -12349,4 +12343,4 @@
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -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', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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>;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ export const enrichEvents: EnrichEventsFunction = async ({

logger.debug('Alert enrichments started');
const isNewRiskScoreModuleAvailable = experimentalFeatures?.riskScoringRoutesEnabled ?? false;
const { uiSettingsClient } = services;

let isNewRiskScoreModuleInstalled = false;
if (isNewRiskScoreModuleAvailable) {
Expand Down