Re: New feature - Define a variable TESTS in settings

2019-07-01 Thread Rene Fleschenberg
Hi, I think it is better to do what Josh mentioned in https://code.djangoproject.com/ticket/30605#comment:2. To elaborate on how this looks in pratice: Write a file called ``settings_test.py`` or such, containing something like this: ``` from .settings import * DEFAULT_FILE_STORAGE = 'inmemory

New feature - Define a variable TESTS in settings

2019-07-01 Thread אורי
Hi, I think it might be useful to define a variable (such as TESTS) in settings, which will only be True when running tests, and then Django will know we are running tests and act accordingly, for example save files in a different directory (such as TESTS_MEDIA_ROOT) and not in the default MEDIA_R