def METHOD_NAME(part, curr_time, last_time):
    if part:
        if not part["elapsed"]:
            part["elapsed"] = elapsed(curr_time, last_time)
        stat = part["status"]
        if stat in completed:
            # TODO (post-34236): remove the expected failure mapping when
            # TODO (post-34236): remove deprecated test methods.
            if stat == "passed" and expected_failure(part["desc"]):
                part["completed"] = "Expected to fail"
            elif part["completed"] == "Unknown":
                part["completed"] = completed[stat]
        elif stat is None or stat == "unknown":
            part["status"] = "passed"
        part["output"] = "\n".join(part["loglines"])