Skip to content

Commit 0d1d842

Browse files
committed
update obs_alert_details_context tests
1 parent 37d53f9 commit 0d1d842

1 file changed

Lines changed: 5 additions & 15 deletions

File tree

x-pack/solutions/observability/test/observability_api_integration/trial/tests/obs_alert_details_context.ts

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -70,16 +70,8 @@ export default function ApiTest({ getService }: ObsFtrProviderContext) {
7070
});
7171
});
7272

73-
it('returns only 1 log category', async () => {
74-
expect(response.body.alertContext).to.have.length(1);
75-
76-
const logCategories = response.body.alertContext.find(
77-
({ key }) => key === 'logCategories'
78-
)?.data as LogCategory[];
79-
80-
expect(
81-
logCategories.map(({ errorCategory }: { errorCategory: string }) => errorCategory)
82-
).to.eql(['Error message from container my-container-a']);
73+
it('returns nothing', async () => {
74+
expect(response.body.alertContext).to.eql([]);
8375
});
8476
});
8577

@@ -317,13 +309,11 @@ export default function ApiTest({ getService }: ObsFtrProviderContext) {
317309
expect(serviceSummary).to.be(undefined);
318310
});
319311

320-
it('returns 1 log category', async () => {
312+
it('returns no log categories', async () => {
321313
const logCategories = response.body.alertContext.find(
322314
({ key }) => key === 'logCategories'
323-
)?.data as LogCategory[];
324-
expect(
325-
logCategories.map(({ errorCategory }: { errorCategory: string }) => errorCategory)
326-
).to.eql(['Error message from service', 'Error message from container my-container-c']);
315+
);
316+
expect(logCategories).to.be(undefined);
327317
});
328318
});
329319

0 commit comments

Comments
 (0)