Opened 17 years ago
Last modified 14 years ago
#5624 closed
Add pre_test signal — at Initial Version
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | Testing framework | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | yes |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
As #5608 was rejected but in our setup we'd still like to be able to load test data in the test database, without polluting the actual doctests (which are mostly used for example/documentation purposes), I went another route and created a new signal, similar to post_syncdb. It's called pre_test and is sent after test database creation, before tests are run. This way it is possible to do some pre-test setup in application management modules (I eg use it to run call_command to loaddata some test_data fixture).
Add pre_test signal