Skip to content

Commit

Permalink
fix: Correctly determine resource property format (#66)
Browse files Browse the repository at this point in the history
* Add format to PropertySchema to correctly determine resource property format

* Update test snapshots
  • Loading branch information
andrii-balitskyi authored Aug 26, 2024
1 parent 8e46c31 commit 638f00d
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/lib/openapi-schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,5 @@ export const PropertySchema: z.ZodSchema<any> = z.object({
'x-deprecated': z.string().default(''),
enum: z.array(z.string()).optional(),
$ref: z.string().optional(),
format: z.string().optional(),
})
2 changes: 1 addition & 1 deletion test/snapshots/blueprint.test.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Generated by [AVA](https://avajs.dev).
{
deprecationMessage: '',
description: 'Foo id',
format: 'string',
format: 'id',
isDeprecated: false,
isUndocumented: false,
jsonType: 'string',
Expand Down
Binary file modified test/snapshots/blueprint.test.ts.snap
Binary file not shown.
6 changes: 3 additions & 3 deletions test/snapshots/seam-blueprint.test.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Generated by [AVA](https://avajs.dev).
{
deprecationMessage: '',
description: 'ID of the `acs_system`.',
format: 'string',
format: 'id',
isDeprecated: false,
isUndocumented: false,
jsonType: 'string',
Expand Down Expand Up @@ -69,7 +69,7 @@ Generated by [AVA](https://avajs.dev).
{
deprecationMessage: '',
description: 'Date and time at which the `acs_system` was created.',
format: 'string',
format: 'datetime',
isDeprecated: false,
isUndocumented: false,
jsonType: 'string',
Expand Down Expand Up @@ -220,7 +220,7 @@ Generated by [AVA](https://avajs.dev).
{
deprecationMessage: '',
description: 'ID of the [workspace](https://docs.seam.co/latest/core-concepts/workspaces) that contains the `acs_system`.',
format: 'string',
format: 'id',
isDeprecated: false,
isUndocumented: false,
jsonType: 'string',
Expand Down
Binary file modified test/snapshots/seam-blueprint.test.ts.snap
Binary file not shown.

0 comments on commit 638f00d

Please sign in to comment.