Lines Matching refs:matchJSONVal

298 def find_in_json(res, outputJSONVal, matchJSONVal, matchJSONKey=None):  argument
302 if type(matchJSONVal) == list:
303 res = find_in_json_list(res, outputJSONVal, matchJSONVal, matchJSONKey)
305 elif type(matchJSONVal) == dict:
306 res = find_in_json_dict(res, outputJSONVal, matchJSONVal)
308 res = find_in_json_other(res, outputJSONVal, matchJSONVal, matchJSONKey)
316 def find_in_json_list(res, outputJSONVal, matchJSONVal, matchJSONKey=None): argument
317 if (type(matchJSONVal) != type(outputJSONVal)):
319 failmsg = failmsg.format(outputJSONVal, matchJSONVal)
324 if len(matchJSONVal) > len(outputJSONVal):
326 failmsg = failmsg.format(len(outputJSONVal), outputJSONVal, len(matchJSONVal), matchJSONVal)
331 for matchJSONIdx, matchJSONVal in enumerate(matchJSONVal):
332 res = find_in_json(res, outputJSONVal[matchJSONIdx], matchJSONVal,
336 def find_in_json_dict(res, outputJSONVal, matchJSONVal): argument
337 for matchJSONKey, matchJSONVal in matchJSONVal.items():
341 failmsg = failmsg.format(matchJSONKey, matchJSONVal, outputJSONVal)
355 if len(matchJSONVal) > 0:
356 res = find_in_json(res, outputJSONVal[matchJSONKey], matchJSONVal, matchJSONKey)
359 res = find_in_json_other(res, outputJSONVal, matchJSONVal, matchJSONKey)
361 res = find_in_json(res, outputJSONVal, matchJSONVal, matchJSONKey)
364 def find_in_json_other(res, outputJSONVal, matchJSONVal, matchJSONKey=None): argument
366 if matchJSONVal != outputJSONVal[matchJSONKey]:
368 … failmsg = failmsg.format(matchJSONKey, matchJSONVal, outputJSONVal[matchJSONKey], outputJSONVal)