Skip to content

Commit a2f6286

Browse files
committed
cleanup
1 parent 65e47ca commit a2f6286

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

x-pack/plugins/security_solution/common/detection_engine/schemas/response/rules_schema.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -665,7 +665,7 @@ describe('rules_schema', () => {
665665
expect(message.schema).toEqual(expected);
666666
});
667667

668-
test('it should NOT validate a type of "query" when it has extra data', () => {
668+
test('it should NOT validate when "exceptions_list" is not expected type', () => {
669669
const payload: Omit<RulesSchema, 'exceptions_list'> & {
670670
exceptions_list?: string;
671671
} = { ...getRulesSchemaMock(), exceptions_list: 'invalid_data' };

x-pack/plugins/security_solution/server/lib/detection_engine/rules/types.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ import { AlertsClient, PartialAlert } from '../../../../../alerts/server';
7878
import { Alert, SanitizedAlert } from '../../../../../alerts/common';
7979
import { SIGNALS_ID } from '../../../../common/constants';
8080
import { RuleTypeParams, PartialFilter } from '../types';
81-
import { ListArrayOrUndefined } from '../../../../common/detection_engine/schemas/types';
81+
import { ListArrayOrUndefined, ListArray } from '../../../../common/detection_engine/schemas/types';
8282

8383
export interface RuleAlertType extends Alert {
8484
params: RuleTypeParams;
@@ -193,7 +193,7 @@ export interface CreateRulesOptions {
193193
references: References;
194194
note: NoteOrUndefined;
195195
version: Version;
196-
exceptionsList: ListArrayOrUndefined;
196+
exceptionsList: ListArray;
197197
actions: RuleAlertAction[];
198198
}
199199

@@ -229,7 +229,7 @@ export interface UpdateRulesOptions {
229229
references: References;
230230
note: NoteOrUndefined;
231231
version: VersionOrUndefined;
232-
exceptionsList: ListArrayOrUndefined;
232+
exceptionsList: ListArray;
233233
actions: RuleAlertAction[];
234234
}
235235

0 commit comments

Comments
 (0)