Skip to content

Commit 6f34ce3

Browse files
committed
Remove flatten tests
1 parent bec3efc commit 6f34ce3

File tree

1 file changed

+1
-17
lines changed

1 file changed

+1
-17
lines changed

packages/toolkit/src/query/tests/utils.test.ts

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
import { vi } from 'vitest'
2-
import {
3-
isOnline,
4-
isDocumentVisible,
5-
flatten,
6-
joinUrls,
7-
} from '@internal/query/utils'
2+
import { isOnline, isDocumentVisible, joinUrls } from '@internal/query/utils'
83

94
afterAll(() => {
105
vi.restoreAllMocks()
@@ -96,14 +91,3 @@ describe('joinUrls', () => {
9691
expect(joinUrls(base, url)).toBe(expected)
9792
})
9893
})
99-
100-
describe('flatten', () => {
101-
test('flattens an array to a depth of 1', () => {
102-
expect(flatten([1, 2, [3, 4]])).toEqual([1, 2, 3, 4])
103-
})
104-
test('does not flatten to a depth of 2', () => {
105-
const flattenResult = flatten([1, 2, [3, 4, [5, 6]]])
106-
expect(flattenResult).not.toEqual([1, 2, 3, 4, 5, 6])
107-
expect(flattenResult).toEqual([1, 2, 3, 4, [5, 6]])
108-
})
109-
})

0 commit comments

Comments
 (0)