Skip to content

Commit 0e4a063

Browse files
committed
test: update snapshots
1 parent 492a4e7 commit 0e4a063

File tree

37 files changed

+113
-246
lines changed

37 files changed

+113
-246
lines changed

packages/openapi-ts-tests/main/scripts/gen-ofetch.mjs

Lines changed: 0 additions & 133 deletions
This file was deleted.
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
import type { ClientOptions } from './types.gen';
4-
import { type ClientOptions as DefaultClientOptions, type Config, createClient, createConfig } from './client';
3+
import { type ClientOptions, type Config, createClient, createConfig } from './client';
4+
import type { ClientOptions as ClientOptions2 } from './types.gen';
55

66
/**
77
* The `createClientConfig()` function will be called on client initialization
@@ -11,6 +11,6 @@ import { type ClientOptions as DefaultClientOptions, type Config, createClient,
1111
* `setConfig()`. This is useful for example if you're using Next.js
1212
* to ensure your client always has the correct values.
1313
*/
14-
export type CreateClientConfig<T extends DefaultClientOptions = ClientOptions> = (override?: Config<DefaultClientOptions & T>) => Config<Required<DefaultClientOptions> & T>;
14+
export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515

16-
export const client = createClient(createConfig<ClientOptions>());
16+
export const client = createClient(createConfig<ClientOptions2>());
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
export * from './types.gen';
3+
export type * from './types.gen';

packages/openapi-ts-tests/main/test/__snapshots__/3.1.x/clients/@hey-api/client-ofetch/base-url-false/types.gen.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3+
export type ClientOptions = {
4+
baseUrl: 'http://localhost:3000/base' | (string & {});
5+
};
6+
37
/**
48
* Model with number-only name
59
*/
@@ -2059,7 +2063,3 @@ export type PutWithFormUrlEncodedData = {
20592063
query?: never;
20602064
url: '/api/v{api-version}/non-ascii-æøåÆØÅöôêÊ字符串';
20612065
};
2062-
2063-
export type ClientOptions = {
2064-
baseUrl: 'http://localhost:3000/base' | (string & {});
2065-
};
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
import type { ClientOptions } from './types.gen';
4-
import { type ClientOptions as DefaultClientOptions, type Config, createClient, createConfig } from './client';
3+
import { type ClientOptions, type Config, createClient, createConfig } from './client';
4+
import type { ClientOptions as ClientOptions2 } from './types.gen';
55

66
/**
77
* The `createClientConfig()` function will be called on client initialization
@@ -11,8 +11,8 @@ import { type ClientOptions as DefaultClientOptions, type Config, createClient,
1111
* `setConfig()`. This is useful for example if you're using Next.js
1212
* to ensure your client always has the correct values.
1313
*/
14-
export type CreateClientConfig<T extends DefaultClientOptions = ClientOptions> = (override?: Config<DefaultClientOptions & T>) => Config<Required<DefaultClientOptions> & T>;
14+
export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515

16-
export const client = createClient(createConfig<ClientOptions>({
16+
export const client = createClient(createConfig<ClientOptions2>({
1717
baseUrl: 'http://localhost:3000/base'
1818
}));
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
export * from './types.gen';
3+
export type * from './types.gen';

packages/openapi-ts-tests/main/test/__snapshots__/3.1.x/clients/@hey-api/client-ofetch/base-url-number/types.gen.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3+
export type ClientOptions = {
4+
baseUrl: 'http://localhost:3000/base' | (string & {});
5+
};
6+
37
/**
48
* Model with number-only name
59
*/
@@ -2059,7 +2063,3 @@ export type PutWithFormUrlEncodedData = {
20592063
query?: never;
20602064
url: '/api/v{api-version}/non-ascii-æøåÆØÅöôêÊ字符串';
20612065
};
2062-
2063-
export type ClientOptions = {
2064-
baseUrl: 'http://localhost:3000/base' | (string & {});
2065-
};
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
import type { ClientOptions } from './types.gen';
4-
import { type ClientOptions as DefaultClientOptions, type Config, createClient, createConfig } from './client';
3+
import { type ClientOptions, type Config, createClient, createConfig } from './client';
4+
import type { ClientOptions as ClientOptions2 } from './types.gen';
55

66
/**
77
* The `createClientConfig()` function will be called on client initialization
@@ -11,8 +11,8 @@ import { type ClientOptions as DefaultClientOptions, type Config, createClient,
1111
* `setConfig()`. This is useful for example if you're using Next.js
1212
* to ensure your client always has the correct values.
1313
*/
14-
export type CreateClientConfig<T extends DefaultClientOptions = ClientOptions> = (override?: Config<DefaultClientOptions & T>) => Config<Required<DefaultClientOptions> & T>;
14+
export type CreateClientConfig<T extends ClientOptions = ClientOptions2> = (override?: Config<ClientOptions & T>) => Config<Required<ClientOptions> & T>;
1515

16-
export const client = createClient(createConfig<ClientOptions>({
16+
export const client = createClient(createConfig<ClientOptions2>({
1717
baseUrl: 'http://localhost:3000/base'
1818
}));
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3-
export * from './types.gen';
3+
export type * from './types.gen';

packages/openapi-ts-tests/main/test/__snapshots__/3.1.x/clients/@hey-api/client-ofetch/base-url-strict/types.gen.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
// This file is auto-generated by @hey-api/openapi-ts
22

3+
export type ClientOptions = {
4+
baseUrl: 'http://localhost:3000/base';
5+
};
6+
37
/**
48
* Model with number-only name
59
*/
@@ -2059,7 +2063,3 @@ export type PutWithFormUrlEncodedData = {
20592063
query?: never;
20602064
url: '/api/v{api-version}/non-ascii-æøåÆØÅöôêÊ字符串';
20612065
};
2062-
2063-
export type ClientOptions = {
2064-
baseUrl: 'http://localhost:3000/base';
2065-
};

0 commit comments

Comments
 (0)