def test_list(self): connection = Connection.make_connection(tc.hostname, tc.admin, tc.password) names = Server.list(connection) self.assertGreater(len(names), 3) self.assertIn("Default|Manage", names)
def servers(self, connection=None): """ Get a list of the servers in the local cluster. """ if connection is None: connection = self.connection return Server.list(connection)
def servers(self, connection=None): """ Get a list of the servers in the local cluster. """ if connection is None: connection = self.connection return Server.list(connection)
def list(self, args, config, connection): stype = args['type'] if stype == None: slist = Server.list(connection) elif stype == 'http': slist = HttpServer.list(connection) elif stype == 'odbc': slist = OdbcServer.list(connection) elif stype == 'xdbc': slist = XdbcServer.list(connection) elif stype == 'webdav': slist = WebDAVServer.list(connection) else: print("Unexpected server type: {0}".format(stype)) sys.exit(1) names = [] for key in slist: (group,name) = key.split('|') if group == args['group']: names.append(name) print(json.dumps(names,sort_keys=True, indent=2))
def list(self, args, config, connection): stype = args['type'] if stype == None: slist = Server.list(connection) elif stype == 'http': slist = HttpServer.list(connection) elif stype == 'odbc': slist = OdbcServer.list(connection) elif stype == 'xdbc': slist = XdbcServer.list(connection) elif stype == 'webdav': slist = WebDAVServer.list(connection) else: print("Unexpected server type: {0}".format(stype)) sys.exit(1) names = [] for key in slist: (group, name) = key.split('|') if group == args['group']: names.append(name) print(json.dumps(names, sort_keys=True, indent=2))
def servers(self, connection=None): if connection is None: connection = self.connection return Server.list(connection)
def servers(self, connection=None): if connection is None: connection = self.connection return Server.list(connection)
def test_list(self): connection = Connection.make_connection(tc.hostname, tc.admin, tc.password) names = Server.list(connection) self.assertGreater(len(names), 3) self.assertIn("Default|Manage", names)
def test_list(self): names = Server.list(self.connection) assert len(names) > 3 assert "Default|Manage" in names
def test_list(self): names = Server.list(self.connection) assert len(names) > 3 assert "Default|Manage" in names