From 9a41c1d0e714a47ffe968682067ddd81710abf0a Mon Sep 17 00:00:00 2001 From: Paul Tavares <56442535+paul-tavares@users.noreply.github.com> Date: Fri, 19 Jun 2020 18:47:47 -0400 Subject: [PATCH] [Endpoint] Fix flaky endpoints list unit test (#69591) * Fix flaky endpoints list unit test * un-skip test Co-authored-by: Elastic Machine --- .../management/pages/endpoint_hosts/view/index.test.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/index.test.tsx b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/index.test.tsx index 68c4e96074181..a3e2a55fc7569 100644 --- a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/index.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/index.test.tsx @@ -175,6 +175,9 @@ describe('when on the hosts page', () => { status: overallStatus, }; policyResponse.Endpoint.policy.applied.actions.push(downloadModelAction); + } else { + // Else, make sure the status of the generated action matches what was passed in + downloadModelAction.status = overallStatus; } if ( @@ -371,7 +374,7 @@ describe('when on the hosts page', () => { }); }); - describe.skip('when showing host Policy Response panel', () => { + describe('when showing host Policy Response panel', () => { let renderResult: ReturnType; beforeEach(async () => { coreStart.http.post.mockImplementation(async (requestOptions) => {