-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
This appears to be possible and somewhat useful, though a little non-obvious given that it doesn't have migrations already generated.
In case it's useful, the steps I used were (approximately):
createdb testsite # (ask Postgres to create a bootstrap DB for the site)
export TEST_DATABASE_NAME=testsite
tests/testsite/manage.py makemigrations photofeed polls turtles
tests/testsite/manage.py migrate
tests/testsite/manage.py shell --command '
import datetime
from polls.models import Question
Question.objects.create(question_text="Who are you?", pub_date=datetime.datetime.now())
'
tests/testsite/manage.py devdata_export
TEST_DATABASE_NAME=testsite_import tests/testsite/manage.py devdata_importMetadata
Metadata
Assignees
Labels
No labels