Opened 14 years ago
Closed 14 years ago
#16037 closed Bug (duplicate)
Multiple databases support for unit testing
| Reported by: | Vladimir Prudnikov | Owned by: | nobody |
|---|---|---|---|
| Component: | Database layer (models, ORM) | Version: | 1.3 |
| Severity: | Normal | Keywords: | test, database, fixtures |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
I use multiple database functionality. Fixtures that contain data for non-default database are not being loaded when I run ./manage.py tests app. It starts loading when I delete all routers from DATABASE_ROUTERS (all data goes to the 'default' database).
There is no option --database for "test" management command.
Change History (2)
comment:1 by , 14 years ago
comment:2 by , 14 years ago
| Resolution: | → duplicate |
|---|---|
| Status: | new → closed |
This feature was already requested in #14610.
Note:
See TracTickets
for help on using tickets.
If I understand correctly, the actual bug is the fact that the
loaddataoperation performed during the test sequence does not honor the database routers.