Skip to content
This repository was archived by the owner on Feb 2, 2023. It is now read-only.
This repository was archived by the owner on Feb 2, 2023. It is now read-only.

Strategies.objects does not merge allOf with own schema #1

@danielbradburn

Description

@danielbradburn

When you have the following schema:

    Derived:
      allOf:
        - type: object
          properties:
            baseProperty:
              type: string
      properties:
        derivedProperty:
          type: string

Strategies.objects will happily generated objects with baseProperty but properties from it's own schema (i.e. derivedProperty) will not be generated. This is because it chooses either the allOf or it's own schema for generation (i.e. for schema in schema.all_of or [schema]). This should be changed to include all_of and it's own schema.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions