fcm-django icon indicating copy to clipboard operation
fcm-django copied to clipboard

FCM_DJANGO_SETTINGS can't be overridden in tests

Open ziima opened this issue 6 years ago • 2 comments

Django provide standard way to override settings with override_settings decorator. Sadly this doesn't work for FCM_DJANGO_SETTINGS.

ziima avatar Dec 19 '18 13:12 ziima

Could anyone perhaps help us with a pull request?

xtrinch avatar May 14 '19 05:05 xtrinch

Temporarily you can try this: https://stackoverflow.com/a/58726299

But the only solution for the package itself is to not use dictionary based settings. That'd require a new major version. Thing is; for many packages that have values that shouldn't exactly be overridden simply for tests (like this package or allauth's social providers), a temporary solution like the one provided in the SO link is good enough.

Andrew-Chen-Wang avatar Jul 14 '21 09:07 Andrew-Chen-Wang