def checkPrepareReqSent(replica: TestReplica, key: str, view_no: int):
    paramsList = getAllArgs(replica._ordering_service, replica._ordering_service._can_prepare)
    rv = getAllReturnVals(replica._ordering_service, replica._ordering_service._can_prepare)
    args = [p['ppReq'].reqIdr for p in paramsList if (p['ppReq'].viewNo == view_no)]
    assert ((key,) in args)
    idx = args.index((key,))
    assert rv[idx]
def checkPrepareReqSent(replica: TestReplica, key: str, view_no: int):
    paramsList = getAllArgs(replica._ordering_service, replica._ordering_service._can_prepare)
    rv = getAllReturnVals(replica._ordering_service, replica._ordering_service._can_prepare)
    args = [p['ppReq'].reqIdr for p in paramsList if (p['ppReq'].viewNo == view_no)]
    assert ((key,) in args)
    idx = args.index((key,))
    assert rv[idx]