We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5f87022 commit 7ddace7Copy full SHA for 7ddace7
tests/unit/test_configs.py
@@ -27,8 +27,11 @@ def test_credentials_from_env(self):
27
self.assertEqual(config.app_id, 'foo-2')
28
self.assertEqual(config.api_key, 'bar-2')
29
finally:
30
- os.environ['ALGOLIA_APP_ID'] = old_app_id
31
- os.environ['ALGOLIA_API_KEY'] = old_api_key
+ if old_app_id:
+ os.environ['ALGOLIA_APP_ID'] = old_app_id
32
+
33
+ if old_api_key:
34
+ os.environ['ALGOLIA_API_KEY'] = old_api_key
35
36
def test_app_id(self):
37
self.assertEqual(self.config.app_id, 'foo')
0 commit comments