I think you can do this all with `with self.settings(...)`.
Like [this for example](https://github.com/mozilla/django-browserid/blob/master/django_browserid/tests/test_base.py#L126)