From a052c4be54492146f6f19c5c7818d0b16c54b442 Mon Sep 17 00:00:00 2001 From: azro Date: Wed, 7 Dec 2022 21:15:24 +0100 Subject: [PATCH] Remove impossible test --- components/grid/__tests__/index.test.tsx | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/components/grid/__tests__/index.test.tsx b/components/grid/__tests__/index.test.tsx index e3b9825e048b..ebd458afccc9 100644 --- a/components/grid/__tests__/index.test.tsx +++ b/components/grid/__tests__/index.test.tsx @@ -2,7 +2,6 @@ import React from 'react'; import { Col, Row } from '..'; import mountTest from '../../../tests/shared/mountTest'; import rtlTest from '../../../tests/shared/rtlTest'; -import useResponsiveObserve from '../../_util/responsiveObserve'; import useBreakpoint from '../hooks/useBreakpoint'; import { render, act } from '../../../tests/utils'; @@ -84,22 +83,6 @@ describe('Grid', () => { expect(asFragment().firstChild).toMatchSnapshot(); }); - it('ResponsiveObserve.unsubscribe should be called when unmounted', () => { - let responsiveObserveRef: any; - const Demo = () => { - const responsiveObserve = useResponsiveObserve(); - responsiveObserveRef = responsiveObserve; - return null; - }; - render(); - const Unmount = jest.spyOn(responsiveObserveRef, 'unsubscribe'); - const { unmount } = render(); - act(() => { - unmount(); - }); - expect(Unmount).toHaveBeenCalled(); - }); - it('should work correct when gutter is object', () => { const { container } = render(); expect(container.querySelector('div')!.style.marginLeft).toEqual('-10px');