Skip to content

Have faker respect Rule.valueOfField(siblingField) #517

Open
@saiichihashimoto

Description

After #336, valueOfField no longer breaks, but faker doesn't generate with them. Ideally, faker would include all validations. It's difficult to layer in the validations at the field level, because the containing object isn't included (and doesn't exist yet, considering the field is part of the definition). We'd have to generate the object schema, then go back through each field and find the validations that used valueOfField() to go and do those, which is somewhat of a back and forth. Might be worth it to ignore validations all together initially, generate the whole object, then layer the validations for each field on top of it. Would have to double check this works fine for objects of objects.

Metadata

Assignees

No one assigned

    Labels

    help wantedPlease help me! I'm lonely.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions