Opened 9 months ago

#27835 new New feature

Make TransactionTestCase raise an error if it accesses non-default database connection without multi_db=True

Reported by: Tim Graham Owned by: nobody
Component: Testing framework Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Suggested by Simon on my PR to fix some test isolation problems, TransactionTestCase and its subclasses could raise an error if they make queries on non-default databases. A rough sketch of this could be implemented is attached.

Attachments (1)

27835.diff (7.0 KB) - added by Tim Graham 9 months ago.

Download all attachments as: .zip

Change History (1)

Changed 9 months ago by Tim Graham

Attachment: 27835.diff added
Note: See TracTickets for help on using tickets.
Back to Top