def testManagerCreatorActionOptions(self): """ test the manager constructor """ # debug = True cluster = None chassis = None down = False all = False # idle = False offline = False node = "" opts = Options() # default options object opts.cluster = TEST_CLUSTER opts.quattor = True opts.all = True opts.forced = True opts.state = True manager = Manager(opts) manager.doit() opts.non_threaded = True manager = Manager(opts) opts.non_threaded = False manager = Manager(opts) manager.doit() opts.non_threaded = False opts.poweron = True Manager(opts).doit() opts.postpoweron = True Manager(opts) # should create a manager opts.postpoweron = False opts.hardreboot = True Manager(opts) opts.hardreboot = False opts.softreboot = True Manager(opts) opts.all = False opts.worker = True opts.forced = False opts.pbsmomstatus = True Manager(opts).doit() opts.pbsmomrestart = True Manager(opts) # should create a manager opts.pbsmomstop = True Manager(opts) # should create a manager opts.pbsmomcleanup = True Manager(opts) # should create a manager opts.runcmd = "echo hello" Manager(opts).doit() # should create a manager