Ejemplo n.º 1
0
    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"
        }
Ejemplo n.º 2
0
    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)
Ejemplo n.º 3
0
    def __init__(self, connection_details):
        self.connection_details = connection_details

        self.adapter = Adapter()
        self.adapter.setup(self.connection_details)