summaryrefslogtreecommitdiff
path: root/service/test/unit/bitmask_libraries/test_keymanager.py
diff options
context:
space:
mode:
authorTulio Casagrande <tcasagra@thoughtworks.com>2016-08-29 18:23:14 -0300
committerTulio Casagrande <tcasagra@thoughtworks.com>2016-08-29 18:59:53 -0300
commitc1a35317fe4ebb82bf7d24dc5d8c171d29c9c501 (patch)
tree74878eaccf9ddce91b33284cd8ed5c67910a219a /service/test/unit/bitmask_libraries/test_keymanager.py
parent840ade44e23add85fbe97b79ee249fc7c1e6adf2 (diff)
[#765] Move combined_ca_bundle to UA initialization
With this change we don't have to create the combined_ca_bundle for every user at every login. To support this change, we started migrating away from the LeapCertificate class that was making the LeapProvider setup more brittle
Diffstat (limited to 'service/test/unit/bitmask_libraries/test_keymanager.py')
-rw-r--r--service/test/unit/bitmask_libraries/test_keymanager.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/service/test/unit/bitmask_libraries/test_keymanager.py b/service/test/unit/bitmask_libraries/test_keymanager.py
index 1a1038b8..2d20e971 100644
--- a/service/test/unit/bitmask_libraries/test_keymanager.py
+++ b/service/test/unit/bitmask_libraries/test_keymanager.py
@@ -26,8 +26,9 @@ from pixelated.config import leap_config
class KeymanagerTest(AbstractLeapTest):
@patch('pixelated.bitmask_libraries.keymanager.KeyManager')
def test_that_keymanager_is_created(self, keymanager_mock):
- LeapCertificate.provider_api_cert = '/some/path/to/provider_ca_cert'
when(self.provider)._discover_nicknym_server().thenReturn('https://nicknym.some-server.test:6425/')
+ self.provider.combined_ca_bundle = 'combined_ca_bundle'
+ self.provider.provider_api_cert = '/some/path/to/provider_ca_cert'
leap_config.gpg_binary = '/path/to/gpg'
Keymanager(self.provider,
@@ -45,7 +46,8 @@ class KeymanagerTest(AbstractLeapTest):
api_uri='https://api.some-server.test:4430',
api_version='1',
uid=self.auth.uuid,
- gpgbinary='/path/to/gpg')
+ gpgbinary='/path/to/gpg',
+ combined_ca_bundle='combined_ca_bundle')
@patch('pixelated.bitmask_libraries.keymanager.KeyManager')
def test_gen_key(self, keymanager_mock):