Skip to content

Commit

Permalink
chore(whatwg-fetch): Switch to importing instead of requiring (#10424)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tobbe committed Apr 5, 2024
1 parent 93f3623 commit f499e86
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion packages/auth/src/__tests__/AuthProvider.test.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
require('whatwg-fetch')
// require('whatwg-fetch')

import React, { useEffect, useState } from 'react'

Expand All @@ -13,6 +13,7 @@ import { renderHook, act } from '@testing-library/react'
import '@testing-library/jest-dom/jest-globals'
import { graphql } from 'msw'
import { setupServer } from 'msw/node'
import 'whatwg-fetch'

import type { CustomTestAuthClient } from './fixtures/customTestAuth'
import { createCustomTestAuth } from './fixtures/customTestAuth'
Expand Down
2 changes: 1 addition & 1 deletion packages/testing/src/web/__tests__/MockHandlers.test.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import 'whatwg-fetch'
import React, { useCallback, useState } from 'react'

import { render, screen, fireEvent, waitFor } from '@testing-library/react'
import { vi, describe, it, expect } from 'vitest'
import 'whatwg-fetch'

import { mockGraphQLQuery } from '../mockRequests'

Expand Down

0 comments on commit f499e86

Please sign in to comment.