@@ -22,7 +22,7 @@ type Pet = components["schemas"]["Pet"];
22
22
type PetInvalid = ErrorResponseJSON < paths [ "/pet/{petId}" ] [ "get" ] > ;
23
23
type PetStatusInvalid = ErrorResponseJSON < paths [ "/pet/findByStatus" ] [ "get" ] > ;
24
24
expectTypeOf < Pet > ( ) . toMatchTypeOf < { name : string } > ( ) ;
25
- expectTypeOf < PetInvalid > ( ) . toMatchTypeOf < { message : string } > ( ) ;
25
+ expectTypeOf < PetInvalid > ( ) . toMatchTypeOf < { message : string } | undefined > ( ) ;
26
26
expectTypeOf < PetStatusInvalid > ( ) . toMatchTypeOf < { message : string } > ( ) ;
27
27
28
28
// Set up hooks
@@ -383,7 +383,7 @@ describe("TypesForRequest", () => {
383
383
it ( "returns correct error" , ( ) => {
384
384
expectTypeOf < GetPet [ "Error" ] > ( ) . toEqualTypeOf < PetInvalid > ( ) ;
385
385
expectTypeOf < FindPetsByStatus [ "Error" ] > ( ) . toEqualTypeOf < PetStatusInvalid > ( ) ;
386
- expectTypeOf < FindPetsByTags [ "Error" ] > ( ) . toEqualTypeOf < never > ( ) ;
386
+ expectTypeOf < FindPetsByTags [ "Error" ] > ( ) . toEqualTypeOf < undefined > ( ) ;
387
387
} ) ;
388
388
389
389
it ( "returns correct path params" , ( ) => {
@@ -430,7 +430,7 @@ describe("TypesForRequest", () => {
430
430
it ( "returns correct SWR config" , ( ) => {
431
431
expectTypeOf < GetPet [ "SWRConfig" ] > ( ) . toEqualTypeOf < SWR . SWRConfiguration < Pet , PetInvalid > > ( ) ;
432
432
expectTypeOf < FindPetsByStatus [ "SWRConfig" ] > ( ) . toEqualTypeOf < SWR . SWRConfiguration < Pet [ ] , PetStatusInvalid > > ( ) ;
433
- expectTypeOf < FindPetsByTags [ "SWRConfig" ] > ( ) . toEqualTypeOf < SWR . SWRConfiguration < Pet [ ] , never > > ( ) ;
433
+ expectTypeOf < FindPetsByTags [ "SWRConfig" ] > ( ) . toEqualTypeOf < SWR . SWRConfiguration < Pet [ ] , undefined > > ( ) ;
434
434
} ) ;
435
435
436
436
it ( "returns correct SWR response" , ( ) => {
@@ -441,7 +441,7 @@ describe("TypesForRequest", () => {
441
441
SWR . SWRResponse < Pet [ ] , PetStatusInvalid , SWR . SWRConfiguration < Pet [ ] , PetStatusInvalid > >
442
442
> ( ) ;
443
443
expectTypeOf < FindPetsByTags [ "SWRResponse" ] > ( ) . toEqualTypeOf <
444
- SWR . SWRResponse < Pet [ ] , never , SWR . SWRConfiguration < Pet [ ] , never > >
444
+ SWR . SWRResponse < Pet [ ] , undefined , SWR . SWRConfiguration < Pet [ ] , undefined > >
445
445
> ( ) ;
446
446
} ) ;
447
447
} ) ;
0 commit comments