Esempio n. 1
0
 def check_output_json(self, want, got, optionsflags):
     """
     Tries to compare want and got as if they were JSON-encoded data
     """
     want, got = strip_quotes(want, got)
     try:
         want_json = json.loads(want)
         got_json = json.loads(got)
     except Exception:
         return False
     return want_json == got_json
Esempio n. 2
0
 def check_output_json(self, want, got, optionsflags):
     """
     Tries to compare want and got as if they were JSON-encoded data
     """
     want, got = strip_quotes(want, got)
     try:
         want_json = json.loads(want)
         got_json = json.loads(got)
     except Exception:
         return False
     return want_json == got_json