Imagine that we have a model like so:
class User(models.Model):
profile = models.ForeignKey('UserProfile')
is_active = models.BooleanField()
And later I want to use it like so:
active_user_factory = fakery.blueprint(User).fields(
is_active=True,
)
empty_username = active_user_factory.m(profile__username='')
email_username = active_user_factory.m(profile__username='email@example.com')
But, currently this does not work. What can be done to pass kwargs to related objects?
Imagine that we have a model like so:
And later I want to use it like so:
But, currently this does not work. What can be done to pass kwargs to related objects?