diff --git a/test/components/Provider.spec.tsx b/test/components/Provider.spec.tsx index b6caf0f37..1c9dce755 100644 --- a/test/components/Provider.spec.tsx +++ b/test/components/Provider.spec.tsx @@ -169,7 +169,7 @@ describe('React', () => { action.type === 'INC' ? state + 1 : state const innerStore = createStore(reducer) - const innerMapStateToProps = vi.fn((state) => ({ + const innerMapStateToProps = vi.fn<[number], TStateProps>((state) => ({ count: state, })) class Inner extends Component { diff --git a/test/typetests/connect-options-and-issues.tsx b/test/typetests/connect-options-and-issues.tsx index be23afc4b..1579397c4 100644 --- a/test/typetests/connect-options-and-issues.tsx +++ b/test/typetests/connect-options-and-issues.tsx @@ -801,8 +801,8 @@ function testRef() { ref={(ref: number) => {}} > - // Should be able to use all refs including legacy string - const classLegacyRef: React.LegacyRef | undefined = undefined + // Should be able to use all refs (except legacy string refs, which go away in React 19) + const classLegacyRef: React.Ref | undefined = undefined ; ;()} @@ -810,7 +810,8 @@ function testRef() { ; {}} > - ; + // TODO Can make this an expected error if we target React 19 exclusively + // ; // ref type should be the typeof the wrapped component ;