i\'m starting the TDD development attitude and am writting unit-tests for my django application. I\'m aware of fixtures and know that\'s the way tests should be executed, bu
A unittest is meant to test without any sideeffects. Though your test would be nothing that is known as unittest. If you want to do it anyway, you can use a custom test runner that is setting up the database (or in your case using the existing db).
You can set the TEST_RUNNER setting in your settings.py file. The default is locate in django.test.simple.run_tests. You can look at the source here:
http://code.djangoproject.com/browser/django/trunk/django/test/simple.py
Copy and paste the code in a new file and remove the following lines from the code:
connection.creation.create_test_db(verbosity, autoclobber=not interactive)
...
connection.creation.destroy_test_db(old_name, verbosity)
This will prevent django from creating a test database and reseting the database configuration of your settings file.