jrocketfingers / sequelize-bakery

Test model generator inspired by model_bakery https://github.com/model-bakers/model_bakery
3 stars 1 forks source link

Generator doesn't take into account validators such as isEmail #2

Closed jrocketfingers closed 1 year ago

jrocketfingers commented 2 years ago

Currently, sequelize-bakery does not take { isEmail: true } validators into account. The inspiration, model_bakery (link to source), uses the fact that Django models use somewhat semantic field types. Sequelize uses validators to constrain a string field into a specific type.

More generally, validators of different kind should be supported, but the primary goal is emails and other frequent and "type-defining" validators (e.g. IP address).

jrocketfingers commented 1 year ago

Forgot to mark this as supported since 0.0.3