def setUp(self): self.adapter = Adapter() self.mysql = { "driver": "mysql", "username": "******", "password": "******", "host": "localhost", "port": 3066, "database": "testdbfortests" } self.postgresql = { "driver": "postgresql", "username": "******", "password": "******", "host": "localhost", "port": 5432, "database": "testdb" } self.wrong = { "driver": "wrongdriver", "username": "******", "password": "******", "host": "localhost", "port": 3066, "database": "testdb" }
def setUp(self): self.id = "5073d616dd0ef409aaaaeeec0fee" self.mysql = { "driver": "mysql", "username": "******", "password": "******", "host": "localhost", "port": 3066, "database": "testdbfortests" } self.adapter = Adapter() self.adapter.setup(self.mysql) self.details = mongo_backend.get_collection("details") self.detail = self.details.find_one({"_id": ObjectId(self.id)}) self.sync = Sync(self.id)
def __init__(self, connection_details): self.connection_details = connection_details self.adapter = Adapter() self.adapter.setup(self.connection_details)