#27057: Use _SavedSettings in setup_test_environment() to store pre-test 
settings
--------------------------------------+--------------------
     Reporter:  cjerdonek             |      Owner:  nobody
         Type:  Cleanup/optimization  |     Status:  new
    Component:  Testing framework     |    Version:  master
     Severity:  Normal                |   Keywords:
 Triage Stage:  Unreviewed            |  Has patch:  0
Easy pickings:  0                     |      UI/UX:  0
--------------------------------------+--------------------
 Currently, `setup_test_environment()` stores pre-test settings in
 "arbitrary (but related)" modules. See
 
[https://github.com/django/django/blob/5890b1613c0a348750a11239ab73a9f0075314ee/django/test/utils.py#L101
 here] for the code.

 This issue is to simplify this code somewhat and make it more consistent
 by storing all pre-test settings in the private `_SavedSettings` class.
 (See [https://code.djangoproject.com/ticket/27019#comment:7 here] and
 subsequent comments for some discussion of this.)

 This will also make it easier to write our first unit test of the "common
 path" of  `setup_test_environment()`.  Currently, only the edge case of
 calling the function twice has its own test.

--
Ticket URL: <https://code.djangoproject.com/ticket/27057>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/052.371792920abe60829c167c9254eed2bc%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to