def setUp(self): JNTTServer.setUp(self) options = JNTOptions({'conf_file':self.getDataFile(self.server_conf)}) options.load() self.dbengine = create_db_engine(options) self.dbmaker = sessionmaker() # Bind the sessionmaker to engine self.dbmaker.configure(bind=self.dbengine) self.dbsession = scoped_session(self.dbmaker) Base.metadata.drop_all(bind=self.dbengine)
def tearDown(self): if self.dbsession is not None: self.dbsession.commit() self.dbsession.close() self.dbsession = None if self.dbmaker is not None: self.dbmaker.close_all() self.dbmaker = None if self.dbengine is not None: self.dbengine.dispose() self.dbengine = None JNTTServer.tearDown(self)
def tearDown(self): self.stopClient() JNTTServer.tearDown(self)
def setUp(self): JNTTServer.setUp(self) self.startClient(self.conf)