On Thu, Oct 7, 2010 at 1:32 PM, girish shabadimath
<[email protected]> wrote:
> Hi all,
>
> im using django 1.2
>
> i dont want django to create test_db for testing, instead should use the
> main database
>
> i have override  run_tests method to do unit tests,,,
> here is the run_tests code:
>
> class Custom_TestSuiteRunner(DjangoTestSuiteRunner):
>
>    def run_tests(self, test_labels, extra_tests=None, **kwargs):
>
>       self.setup_test_environment()
>       suite = self.build_suite(test_labels, extra_tests)
>       #old_config = self.setup_databases()         commented to use main
> database

Before you start randomly commenting out code, you might want to check
out what the code actually does.

Part of the process of creating a test database is to verifies the
capabilities of the database -- most notably, whether the database
supports transactions, which has a profound effect on the operation of
subsequent test cases.

If you don't want to use a separate test database, then you'll need to
replicate the feature validation logic. If you don't, you'll get
exactly the error you describe.

Yours,
Russ Magee %-)

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to