File tree Expand file tree Collapse file tree
x-pack/plugins/security_solution/public/detections/containers/detection_engine/alerts Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import {
1313 mockSignalIndex ,
1414 mockUserPrivilege ,
1515 mockHostIsolation ,
16- mockUserProfiles ,
1716} from './mock' ;
1817import {
1918 fetchQueryAlerts ,
@@ -23,7 +22,6 @@ import {
2322 createHostIsolation ,
2423 updateAlertStatusByQuery ,
2524 updateAlertStatusByIds ,
26- suggestUsers ,
2725} from './api' ;
2826import { coreMock } from '@kbn/core/public/mocks' ;
2927
@@ -266,28 +264,4 @@ describe('Detections Alerts API', () => {
266264 expect ( hostIsolationResponse ) . toEqual ( mockHostIsolation ) ;
267265 } ) ;
268266 } ) ;
269-
270- describe ( 'suggestUsers' , ( ) => {
271- beforeEach ( ( ) => {
272- fetchMock . mockClear ( ) ;
273- fetchMock . mockResolvedValue ( mockUserProfiles ) ;
274- } ) ;
275-
276- test ( 'check parameter url' , async ( ) => {
277- await suggestUsers ( { searchTerm : 'name1' } ) ;
278- expect ( fetchMock ) . toHaveBeenCalledWith (
279- '/api/detection_engine/signals/suggest_users' ,
280- expect . objectContaining ( {
281- method : 'GET' ,
282- version : '2023-10-31' ,
283- query : { searchTerm : 'name1' } ,
284- } )
285- ) ;
286- } ) ;
287-
288- test ( 'happy path' , async ( ) => {
289- const alertsResp = await suggestUsers ( { searchTerm : '' } ) ;
290- expect ( alertsResp ) . toEqual ( mockUserProfiles ) ;
291- } ) ;
292- } ) ;
293267} ) ;
You can’t perform that action at this time.
0 commit comments