diff --git a/packages/peregrine/lib/talons/Header/__tests__/useCartTrigger.spec.js b/packages/peregrine/lib/talons/Header/__tests__/useCartTrigger.spec.js index 042de8c925c..aff89255885 100644 --- a/packages/peregrine/lib/talons/Header/__tests__/useCartTrigger.spec.js +++ b/packages/peregrine/lib/talons/Header/__tests__/useCartTrigger.spec.js @@ -4,7 +4,9 @@ import { createTestInstance } from '@magento/peregrine'; import { useCartTrigger } from '../useCartTrigger'; jest.mock('@apollo/client', () => { + const apolloClient = jest.requireActual('@apollo/client'); return { + ...apolloClient, useApolloClient: jest.fn(), useQuery: jest.fn(() => ({ data: { cart: { total_quantity: 10 } } })), useMutation: jest.fn(() => [jest.fn()])