Arches is a web platform for creating, managing, & visualizing geospatial data. Arches was inspired by the needs of the Cultural Heritage community, particularly the widespread need of organizations to build & manage cultural heritage inventories
GNU Affero General Public License v3.0
212
stars
142
forks
source link
Hide complexity of sync_overridden_settings_to_arches() context manager #11525
Earlier I added a context manager sync_overridden_settings_to_arches() to allow us to use the @override_settings decorator from Django in cases where the functionality under test uses the SystemSettings object instead of the vanilla django.conf.settings object.
This is a little finicky/delicate/verbose.
We could hide this complexity in our own @override_settings decorator, and just remember to import it from arches.test.utils rather than django.test.utils. One and done.
Earlier I added a context manager
sync_overridden_settings_to_arches()
to allow us to use the@override_settings
decorator from Django in cases where the functionality under test uses theSystemSettings
object instead of the vanilladjango.conf.settings
object.This is a little finicky/delicate/verbose.
We could hide this complexity in our own
@override_settings
decorator, and just remember to import it fromarches.test.utils
rather thandjango.test.utils
. One and done.