def get_testcase(rowid):
    try:
        dbrow = webhelpers.dbsession.query(models.TestCase).get(int(rowid))
        if dbrow is None:
            raise framework.HttpErrorNotFound("No such testcase id.")
    except __HOLE__:
            raise framework.HttpErrorNotFound("Bad id value.")
    return dbrow
dataset/ETHPy150Open kdart/pycopia/QA/pycopia/QA/webui/testcases.py/get_testcase