Skip to content

Commit

Permalink
chore: resolve lint issues encountered using pnpm installation (#313)
Browse files Browse the repository at this point in the history
  • Loading branch information
BQXBQX authored Dec 6, 2024
1 parent 0cafa79 commit 5321c19
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/utils.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import type { ReactElement } from 'react';
import React, { createRef, StrictMode } from 'react';
import type { RenderOptions } from '@testing-library/react';
import type { RenderOptions, RenderResult } from '@testing-library/react';
import { act, render } from '@testing-library/react';
import MockDate from 'mockdate';
import { _rs as onEsResize } from 'rc-resize-observer/es/utils/observerUtil';
import { _rs as onLibResize } from 'rc-resize-observer/lib/utils/observerUtil';
import type { ReactElement } from 'react';
import React, { createRef, StrictMode } from 'react';

export function assertsExist<T>(item?: T): asserts item is T {
expect(item).not.toBeUndefined();
Expand All @@ -29,7 +29,7 @@ export const sleep = async (timeout = 0) => {
});
};

const customRender = (ui: ReactElement, options?: Omit<RenderOptions, 'wrapper'>) =>
const customRender = (ui: ReactElement, options?: Omit<RenderOptions, 'wrapper'>): RenderResult =>
render(ui, { wrapper: StrictMode, ...options });

export function renderHook<T>(func: () => T): { result: React.RefObject<T> } {
Expand Down

0 comments on commit 5321c19

Please sign in to comment.