[Detections Response] Remove unused test (#224108)

## Summary

Addresses https://github.com/elastic/kibana/issues/151636 .

This test was leftover from migration. Does not appear to be used.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
This commit is contained in:
Yara Tercero 2025-06-20 12:39:25 -07:00 committed by GitHub
parent 025aacd302
commit f2d4278086
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 0 additions and 112 deletions

View file

@ -156,7 +156,6 @@ enabled:
- x-pack/platform/test/alerting_api_integration/spaces_only/tests/action_task_params/config.ts
- x-pack/test/api_integration_basic/config.ts
- x-pack/test/api_integration/apis/cases/config.ts
- x-pack/test/api_integration/apis/lists/config.ts
- x-pack/test/api_integration/apis/security/config.ts
- x-pack/test/banners_functional/config.ts
- x-pack/test/cases_api_integration/security_and_spaces/config_basic.ts

View file

@ -1,17 +0,0 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
import { FtrConfigProviderContext } from '@kbn/test';
export default async function ({ readConfigFile }: FtrConfigProviderContext) {
const baseIntegrationTestsConfig = await readConfigFile(require.resolve('../../config.ts'));
return {
...baseIntegrationTestsConfig.getAll(),
testFiles: [require.resolve('.')],
};
}

View file

@ -1,78 +0,0 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
import expect from '@kbn/expect';
import { ENDPOINT_LIST_ID } from '@kbn/securitysolution-list-constants';
import { FtrProviderContext } from '../../ftr_provider_context';
export default function ({ getService }: FtrProviderContext) {
const esArchiver = getService('esArchiver');
const supertest = getService('supertest');
// FLAKY: https://github.com/elastic/kibana/issues/151636
describe.skip('Lists API', () => {
before(async () => await esArchiver.load('x-pack/test/functional/es_archives/lists'));
after(async () => await esArchiver.unload('x-pack/test/functional/es_archives/lists'));
it('should return a 400 if an endpoint exception item with a list-based entry is provided', async () => {
const badItem = {
namespace_type: 'agnostic',
description: 'bad endpoint item for testing',
name: 'bad endpoint item',
list_id: ENDPOINT_LIST_ID,
type: 'simple',
entries: [
{
type: 'list',
field: 'some.field',
operator: 'included',
list: {
id: 'somelist',
type: 'keyword',
},
},
],
};
const { body } = await supertest
.post(`/api/exception_lists/items`)
.set('kbn-xsrf', 'xxx')
.send(badItem)
.expect(400);
expect(body.message).to.eql([
'Invalid value "list" supplied to "type"',
'Invalid value "undefined" supplied to "value"',
'Invalid value "undefined" supplied to "entries"',
]);
});
it('should return a 400 if endpoint exception entry has disallowed field', async () => {
const fieldName = 'file.Ext.quarantine_path';
const badItem = {
namespace_type: 'agnostic',
description: 'bad endpoint item for testing',
name: 'bad endpoint item',
list_id: ENDPOINT_LIST_ID,
type: 'simple',
entries: [
{
type: 'match',
field: fieldName,
operator: 'included',
value: 'doesnt matter',
},
],
};
const { body } = await supertest
.post(`/api/exception_lists/items`)
.set('kbn-xsrf', 'xxx')
.send(badItem)
.expect(400);
expect(body.message).to.eql(`cannot add endpoint exception item on field ${fieldName}`);
});
});
}

View file

@ -1,15 +0,0 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
import { FtrProviderContext } from '../../ftr_provider_context';
export default function listsAPIIntegrationTests({ loadTestFile }: FtrProviderContext) {
describe('Lists plugin', function () {
this.tags(['lists']);
loadTestFile(require.resolve('./create_exception_list_item'));
});
}

View file

@ -58,7 +58,6 @@
"@kbn/dev-utils",
"@kbn/dev-proc-runner",
"@kbn/ftr-common-functional-services",
"@kbn/securitysolution-list-constants",
"@kbn/expect",
"@kbn/dev-cli-errors",
"@kbn/ci-stats-reporter",