Ejemplo n.º 1
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
Ejemplo n.º 2
0
 def setUp(self):
     BaseSoledadTest.setUp(self)
     CouchDBTestCase.setUp(self)
     main_test_class = getattr(self, 'main_test_class', None)
     if main_test_class is not None:
         main_test_class.setUp(self)
     self._couch_url = 'http://localhost:%d' % self.wrapper.port
Ejemplo n.º 3
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
Ejemplo n.º 4
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self._state = CouchServerState(
         self._couch_url, 'shared', 'tokens')
Ejemplo n.º 5
0
 def setUp(self):
     BaseSoledadTest.setUp(self)
     CouchDBTestCase.setUp(self)
     main_test_class = getattr(self, 'main_test_class', None)
     if main_test_class is not None:
         main_test_class.setUp(self)
     self._couch_url = 'http://localhost:%d' % self.wrapper.port
Ejemplo n.º 6
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
Ejemplo n.º 7
0
 def tearDown(self):
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
     # delete remote database
     db = CouchDatabase.open_database(urljoin(self._couch_url, 'shared'),
                                      create=True,
                                      ensure_ddocs=True)
     db.delete_database()
Ejemplo n.º 8
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
Ejemplo n.º 9
0
 def tearDown(self):
     # delete remote database
     db = CouchDatabase.open_database(
         urljoin(self._couch_url, 'shared'),
         create=True,
         ensure_ddocs=True)
     db.delete_database()
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.db = CouchDatabase.open_database(
         urljoin(self._couch_url, 'user-user-uuid'),
         create=True,
         replica_uid='replica',
         ensure_ddocs=True)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
Ejemplo n.º 11
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.db = CouchDatabase.open_database(urljoin(self._couch_url,
                                                   'user-user-uuid'),
                                           create=True,
                                           replica_uid='replica',
                                           ensure_ddocs=True)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.user = ('user-%s' % uuid4().hex)
     self.db = CouchDatabase.open_database(
         urljoin(self.couch_url, 'user-' + self.user),
         create=True,
         replica_uid='replica',
         ensure_ddocs=True)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self.startTwistedServer()
Ejemplo n.º 13
0
 def tearDown(self):
     BaseSoledadTest.tearDown(self)
     CouchDBTestCase.tearDown(self)
     main_test_class = getattr(self, 'main_test_class', None)
     if main_test_class is not None:
         main_test_class.tearDown(self)
     # delete the test database
     try:
         db = CouchDatabase(self._couch_url, 'test')
         db.delete_database()
     except DatabaseDoesNotExist:
         pass
Ejemplo n.º 14
0
 def tearDown(self):
     BaseSoledadTest.tearDown(self)
     CouchDBTestCase.tearDown(self)
     main_test_class = getattr(self, 'main_test_class', None)
     if main_test_class is not None:
         main_test_class.tearDown(self)
     # delete the test database
     try:
         db = CouchDatabase(self._couch_url, 'test')
         db.delete_database()
     except DatabaseDoesNotExist:
         pass
Ejemplo n.º 15
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     # create the databases
     CouchDatabase.open_database(urljoin(self._couch_url, 'shared'),
                                 create=True,
                                 ensure_ddocs=True)
     CouchDatabase.open_database(urljoin(self._couch_url, 'tokens'),
                                 create=True,
                                 ensure_ddocs=True)
     self._state = CouchServerState(self._couch_url, 'shared', 'tokens')
Ejemplo n.º 16
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
     # create the databases
     db = CouchDatabase.open_database(
         urljoin(self.couch_url, ('shared-%s' % (uuid4().hex))),
         create=True,
         ensure_ddocs=True)
     self.addCleanup(db.delete_database)
     self._state = CouchServerState(self.couch_url)
     self._state.open_database = mock.Mock(return_value=db)
Ejemplo n.º 17
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
     # create the databases
     CouchDatabase.open_database(urljoin(self._couch_url, 'shared'),
                                 create=True,
                                 ensure_ddocs=True)
     CouchDatabase.open_database(urljoin(self._couch_url, 'tokens'),
                                 create=True,
                                 ensure_ddocs=True)
     self._state = CouchServerState(self._couch_url)
Ejemplo n.º 18
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     # create the databases
     CouchDatabase.open_database(
         urljoin(self._couch_url, 'shared'),
         create=True,
         ensure_ddocs=True)
     CouchDatabase.open_database(
         urljoin(self._couch_url, 'tokens'),
         create=True,
         ensure_ddocs=True)
     self._state = CouchServerState(
         self._couch_url, 'shared', 'tokens')
Ejemplo n.º 19
0
 def setUp(self):
     # the order of the following initializations is crucial because of
     # dependencies.
     # XXX explain better
     CouchDBTestCase.setUp(self)
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     TestCaseWithServer.setUp(self)
     # create the databases
     CouchDatabase.open_database(
         urljoin(self._couch_url, 'shared'),
         create=True,
         ensure_ddocs=True)
     CouchDatabase.open_database(
         urljoin(self._couch_url, 'tokens'),
         create=True,
         ensure_ddocs=True)
     self._state = CouchServerState(self._couch_url)
Ejemplo n.º 20
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self.user = ('user-%s' % uuid.uuid4().hex)
Ejemplo n.º 21
0
 def tearDown(self):
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
Ejemplo n.º 22
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self._couch_url = 'http://localhost:' + str(self.wrapper.port)
 def tearDown(self):
     self.db.delete_database()
     self.db.close()
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
Ejemplo n.º 24
0
 def tearDown(self):
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
     shutil.rmtree(self.tempdir)
Ejemplo n.º 25
0
 def tearDown(self):
     self.db.delete_database()
     self.db.close()
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
Ejemplo n.º 26
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
Ejemplo n.º 27
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self._couch_url = "http://localhost:" + str(self.wrapper.port)
Ejemplo n.º 28
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")
     self.user = ('user-%s' % uuid.uuid4().hex)
Ejemplo n.º 29
0
 def tearDown(self):
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
     shutil.rmtree(self.tempdir)
Ejemplo n.º 30
0
 def tearDown(self):
     CouchDBTestCase.tearDown(self)
     TestCaseWithServer.tearDown(self)
Ejemplo n.º 31
0
 def setUp(self):
     TestCaseWithServer.setUp(self)
     CouchDBTestCase.setUp(self)
     self.tempdir = tempfile.mkdtemp(prefix="leap_tests-")