mirror of
https://github.com/django/django.git
synced 2025-10-24 14:16:09 +00:00
@@ -14,9 +14,11 @@ from .models import Article, ArticleRef, Authors, Reviewers, Scientist, Scientis
|
||||
# because they're evaluated when the model class is defined. As a consequence,
|
||||
# @override_settings doesn't work, and the tests depend
|
||||
|
||||
|
||||
def sql_for_table(model):
|
||||
return '\n'.join(connection.creation.sql_create_model(model, no_style())[0])
|
||||
|
||||
|
||||
def sql_for_index(model):
|
||||
return '\n'.join(connection.creation.sql_indexes_for_model(model, no_style()))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user