On Mon, Jan 11, 2016 at 07:06:22AM -0800, Brutus Schraiber wrote:
> Hi all…
>
> I have some models in a `test.py` file. How can I view the SQL that will be
> generated for them?
>
> Something like `django-admin sql` or similar but for models defined in
> `test.py` not in `models.py`.
Django always expects models in the models module. If you need a
separate set of models just for tests, you'll need to set up a
separate test app with any additional test models.
Good luck,
Michal
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/20160116231915.GX20308%40koniiiik.org.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment