diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/hooks/use_package_policy.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/hooks/use_package_policy.tsx index 49425e62e8a6b..ec2771df920cd 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/hooks/use_package_policy.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/hooks/use_package_policy.tsx @@ -74,7 +74,7 @@ export function usePackagePolicyWithRelatedData( description: '', namespace: '', policy_id: '', - policy_ids: [''], + policy_ids: [], enabled: true, inputs: [], version: '', diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/index.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/index.test.tsx index f893f7a7e7aeb..384920b252a5a 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/index.test.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/edit_package_policy_page/index.test.tsx @@ -564,6 +564,7 @@ describe('edit package policy page', () => { policy_ids: ['agent-policy-1', 'agent-policy-2'], }) ); + expect(sendGetAgentStatus).toHaveBeenCalledTimes(1); }); it('should not remove managed policy when policies are modified', async () => {