Coverage for config/test.py: 100.00%

5 statements  

« prev     ^ index     » next       coverage.py v7.9.1, created at 2025-06-13 16:05 -0700

1"""With these settings, tests run faster.""" 

2 

3from .settings import * # noqa 

4 

5# GENERAL 

6# ------------------------------------------------------------------------------ 

7# https://docs.djangoproject.com/en/dev/ref/settings/#secret-key 

8# SECRET_KEY = env( 

9# "SECRET_KEY", 

10# default="!!!SET SECRET_KEY!!!", 

11# ) 

12# https://docs.djangoproject.com/en/dev/ref/settings/#test-runner 

13TEST_RUNNER = "django.test.runner.DiscoverRunner" 

14 

15# CACHES 

16# ------------------------------------------------------------------------------ 

17# https://docs.djangoproject.com/en/dev/ref/settings/#caches 

18CACHES = { 

19 "default": { 

20 "BACKEND": "django.core.cache.backends.locmem.LocMemCache", 

21 "LOCATION": "", 

22 } 

23} 

24 

25# PASSWORDS 

26# ------------------------------------------------------------------------------ 

27# https://docs.djangoproject.com/en/dev/ref/settings/#password-hashers 

28PASSWORD_HASHERS = ["django.contrib.auth.hashers.MD5PasswordHasher"] 

29 

30# TEMPLATES 

31# ------------------------------------------------------------------------------ 

32# APP_DIRS needs to be set to 'False' in config/settings.py to 

33# use this section - 20230729 

34# TEMPLATES[-1]["OPTIONS"]["loaders"] = [ 

35# ( 

36# "django.template.loaders.cached.Loader", 

37# [ 

38# "django.template.loaders.filesystem.Loader", 

39# "django.template.loaders.app_directories.Loader", 

40# ], 

41# ) 

42# ] 

43# The following is being used in updated django-cookiecutter - 20230801 

44TEMPLATES[0]["OPTIONS"]["debug"] = True # type: ignore # noqa: F405 

45 

46# EMAIL 

47# ------------------------------------------------------------------------------ 

48# https://docs.djangoproject.com/en/dev/ref/settings/#email-backend 

49# EMAIL_BACKEND = "django.core.mail.backends.locmem.EmailBackend" 

50 

51# Your stuff... 

52# ------------------------------------------------------------------------------