We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When generating this spec with orval, the mock generated with orval return an error in .msw file.
.msw
Orval version: 7.5.0
export const getCreatePrivateNoteResponseMock = (): PrivateNote => (...{href: faker.string.alpha(20), noteType: faker.helpers.arrayElement(Object.values(NoteType)),})
YAML reproduction
paths: /shared-notes: post: tags: ['BeneficiaryNotes'] operationId: createSharedNote summary: Create a shared note for the beneficiary. x-with-target-resource: true parameters: - name: beneficiaryRef in: path required: true description: Beneficiary reference. x-data-type: BeneficiaryRef x-target-resource: true schema: type: string format: uuid responses: '201': description: The new note has been recorded. content: application/json: schema: $ref: '#/components/schemas/SharedNote' headers: Location: schema: type: string description: Relative URL to access this note. /private-notes: post: tags: ['BeneficiaryNotes'] operationId: createPrivateNote summary: Create a private note for the beneficiary. x-with-target-resource: true parameters: - name: beneficiaryRef in: path required: true description: Beneficiary reference. x-data-type: BeneficiaryRef x-target-resource: true schema: type: string format: uuid responses: '201': description: The new note has been recorded. content: application/json: schema: $ref: '#/components/schemas/PrivateNote' headers: Location: schema: type: string description: Relative URL to access this note. components: schemas: Note: allOf: - type: object required: - href - noteType properties: href: type: string x-data-type: NoteHrefValue example: '/notes/f2584c95-7df7-4f02-8181-8d0f3547cb87' noteType: $ref: '#/components/schemas/NoteType' discriminator: propertyName: noteType mapping: SharedNote: '#/components/schemas/SharedNote' PrivateNote: '#/components/schemas/PrivateNote' NoteType: type: string enum: - SharedNote - PrivateNote example: 'SharedNote' SharedNote: allOf: - $ref: '#/components/schemas/Note' - type: object properties: professions: type: array items: - type: object required: - name properties: name: type: string example: 'Nurse' visibleForBeneficiary: type: boolean example: true PrivateNote: allOf: - $ref: '#/components/schemas/Note'
The text was updated successfully, but these errors were encountered:
@melloware you can assign me, I'll have a look
Sorry, something went wrong.
Done!
AllieJonsson
Successfully merging a pull request may close this issue.
When generating this spec with orval, the mock generated with orval return an error in
.msw
file.Orval version: 7.5.0
YAML reproduction
The text was updated successfully, but these errors were encountered: