MCPcopy Create free account
hub / github.com/apache/cloudstack / parse_input_runtcs

Method parse_input_runtcs

tools/marvin/marvin/deployAndRun.py:208–227  ·  view source on GitHub ↗

Parses,reads the options and verifies for the config file

(self, inputs)

Source from the content-addressed store, hash-verified

206 @VerifyAndExit(
207 "cmd failed, may be invalid input options, please check help")
208 def parse_input_runtcs(self, inputs):
209 '''
210 Parses,reads the options and verifies for the config file
211 '''
212 if inputs:
213 out_dict = {}
214 args = inputs.strip().split(' ')
215 for item in args:
216 (key, value) = item.split('=')
217 out_dict[key] = value
218 self.__configFile = out_dict.get('config-file', None)
219 self.__zone = out_dict.get("zone", None)
220 self.__hypervisorType = out_dict.get("hyp-type", None)
221 self.__tcPath = out_dict.get("tc-path",)
222 self.__requiredHw = out_dict.get("required-hardware")
223 if not all([self.__tcPath, self.__configFile]):
224 return FAILED
225 print("\n==== Parsing Input Options Successful ====")
226 return SUCCESS
227 return FAILED
228
229 @VerifyAndExit("Marvin initialization failed, please check")
230 def start_marvin(self):

Callers 2

do_runtestMethod · 0.95

Calls 2

getMethod · 0.65
allFunction · 0.50

Tested by

no test coverage detected