wip
This commit is contained in:
parent
e86e432102
commit
28eda9e899
5 changed files with 121 additions and 184 deletions
|
|
@ -1,14 +1,12 @@
|
|||
from faker import Faker
|
||||
from polyfactory.factories.pydantic_factory import ModelFactory
|
||||
|
||||
from learn_sql_model.models.{{modelname.lower()}} import {{modelname}}
|
||||
from learn_sql_model.factories.pet import PetFactory
|
||||
from learn_sql_model.models.{{ modelname }} import {{ modelname }}
|
||||
from learn_sql_model.models.pet import Pet
|
||||
|
||||
|
||||
class {{modelname}}Factory(ModelFactory[{{modelname.lower()}}]):
|
||||
__model__ = {{modelname}}
|
||||
class {{ modelname }}Factory(ModelFactory[{{ modelname }}]):
|
||||
__model__ = {{ modelname }}
|
||||
__faker__ = Faker(locale="en_US")
|
||||
__set_as_default_factory_for_type__ = True
|
||||
id = None
|
||||
|
||||
__random_seed__ = 10
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue