mockSearchOverview.ts 497 B

1234567891011121314
  1. // Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. import type { SearchQuery } from '#shared/graphql/types.ts'
  3. import type { ConfidentTake } from '#shared/types/utils.ts'
  4. import { mockGraphQLApi } from '#tests/support/mock-graphql-api.ts'
  5. import { SearchDocument } from '../queries/searchOverview.api.ts'
  6. export const mockSearchOverview = (
  7. search: ConfidentTake<SearchQuery, 'search'>,
  8. ) => {
  9. return mockGraphQLApi(SearchDocument).willResolve({
  10. search,
  11. })
  12. }