summaryrefslogtreecommitdiff
path: root/common/src/leap/soledad
diff options
context:
space:
mode:
Diffstat (limited to 'common/src/leap/soledad')
-rw-r--r--common/src/leap/soledad/common/tests/test_sync_target.py9
-rw-r--r--common/src/leap/soledad/common/tests/util.py2
2 files changed, 7 insertions, 4 deletions
diff --git a/common/src/leap/soledad/common/tests/test_sync_target.py b/common/src/leap/soledad/common/tests/test_sync_target.py
index 8f9e6b34..587debcb 100644
--- a/common/src/leap/soledad/common/tests/test_sync_target.py
+++ b/common/src/leap/soledad/common/tests/test_sync_target.py
@@ -147,7 +147,8 @@ class TestSoledadParseReceivedDocResponse(SoledadWithCouchServerMixin):
#
-def make_local_db_and_soledad_target(test, path='test',
+def make_local_db_and_soledad_target(
+ test, path='test',
source_replica_uid=uuid4().hex):
test.startTwistedServer()
db = test.request_state._create_database(os.path.basename(path))
@@ -155,9 +156,11 @@ def make_local_db_and_soledad_target(test, path='test',
return db, st
-def make_local_db_and_token_soledad_target(test,
+def make_local_db_and_token_soledad_target(
+ test,
source_replica_uid=uuid4().hex):
- db, st = make_local_db_and_soledad_target(test, path='test',
+ db, st = make_local_db_and_soledad_target(
+ test, path='test',
source_replica_uid=source_replica_uid)
st.set_token_credentials('user-uuid', 'auth-token')
return db, st
diff --git a/common/src/leap/soledad/common/tests/util.py b/common/src/leap/soledad/common/tests/util.py
index 5506d789..d42edf18 100644
--- a/common/src/leap/soledad/common/tests/util.py
+++ b/common/src/leap/soledad/common/tests/util.py
@@ -192,7 +192,7 @@ def soledad_sync_target(test, path, source_replica_uid=uuid4().hex):
# TestCase. This is needed so trial knows that it has to manage a reactor and
# wait for deferreds returned by tests to be fired.
BaseLeapTest = type(
- 'BaseLeapTest', (unittest.TestCase,), dict(BaseLeapTest.__dict__))
+ 'BaseLeapTest', (unittest.TestCase,), dict(BaseLeapTest.__dict__))
class BaseSoledadTest(BaseLeapTest, MockedSharedDBTest):