Skip to content
New issue

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

Bug: dependentOn: allOf with "x-faker: false" #52

Closed
siggi-k opened this issue Sep 12, 2024 · 0 comments · Fixed by #56
Closed

Bug: dependentOn: allOf with "x-faker: false" #52

siggi-k opened this issue Sep 12, 2024 · 0 comments · Fixed by #56
Assignees

Comments

@siggi-k
Copy link

siggi-k commented Sep 12, 2024

Invoice.yaml

title: Invoice
x-table: invoices
type: object
properties:
  id:
    type: integer
  reference_invoice:
    allOf:
      - $ref: '#/components/schemas/Invoice'
      - x-faker: false
      - description: This field is only set on invoices of type "cancellation_invoice"

When inserting this code, 'Invoice' itself is also listed as dependent in the dependentOn function in InvoiceFaker.php. This should not happen for two reasons:

  1. It fundamentally makes no sense to mark itself as dependent.
  2. The setting x-faker: false should result in the referenced relation not being taken as dependent.
@siggi-k siggi-k changed the title Bug: dependentOn Bug: dependentOn: allOf with "x-faker: false" Sep 12, 2024
@SOHELAHMED7 SOHELAHMED7 self-assigned this Sep 24, 2024
@SOHELAHMED7 SOHELAHMED7 linked a pull request Sep 25, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants