tools/fuchsia/comparative_tester/test_results.py
def ReadResultLineFromJson(dct: Dict[str, Any]) -> ResultLine:
  """Converts a JSON dictionary object into a ResultLine.

  Args:
    dct (Dict[str, Any]): The JSON object to be parsed as a ResultLine. MUST
        contain the strings 'description', 'measurement', and 'unit'.

  Raises:
    KeyError: If the passed in dictionary does not contain the three required
        strings that a serialized ResultLine must contain.

  Returns:
    ResultLine: A ResultLine object reconstituted from the JSON dictionary.
  """
  return ResultLine(dct["description"], float(dct["measurement"]), dct["unit"])
Converts a JSON dictionary object into a ResultLine.

  Args:
    dct (Dict[str, Any]): The JSON object to be parsed as a ResultLine. MUST
        contain the strings 'description', 'measurement', and 'unit'.

  Raises:
    KeyError: If the passed in dictionary does not contain the three required
        strings that a serialized ResultLine must contain.

  Returns:
    ResultLine: A ResultLine object reconstituted from the JSON dictionary.
  
Converts a JSON dictionary object into a ResultLine.
Converts a JSON dictionary object into a ResultLine .
def ReadResultLineFromJson(dct: Dict[str, Any]) -> ResultLine:
  return ResultLine(dct["description"], float(dct["measurement"]), dct["unit"])
def ReadResultLineFromJson ( dct : Dict [ str , Any ] ) -> ResultLine : return ResultLine ( dct [ "description" ] , float ( dct [ "measurement" ] ) , dct [ "unit" ] )
Converts a JSON dictionary object into a ResultLine.
Converts a JSON dictionary object into a ResultLine .
"""Converts a JSON dictionary object into a ResultLine.

  Args:
    dct (Dict[str, Any]): The JSON object to be parsed as a ResultLine. MUST
        contain the strings 'description', 'measurement', and 'unit'.

  Raises:
    KeyError: If the passed in dictionary does not contain the three required
        strings that a serialized ResultLine must contain.

  Returns:
    ResultLine: A ResultLine object reconstituted from the JSON dictionary.
  """
A ResultLine object reconstituted from the JSON dictionary.
A ResultLine object reconstituted from the JSON dictionary .
ResultLine
If the passed in dictionary does not contain the three required
strings that a serialized ResultLine must contain.
If the passed in dictionary does not contain the three required strings that a serialized ResultLine must contain .
KeyError
dct
Dict[str, Any]
The JSON object to be parsed as a ResultLine. MUST
contain the strings 'description', 'measurement', and 'unit'.
The JSON object to be parsed as a ResultLine . MUST contain the strings ' description ' ' measurement ' and ' unit ' .