def test_parse_referent(referent): ret = parse_bytecode(referent)
def test_file_input(): with open(complete_test_file, 'r') as fp: src = fp.read() ret = parse_bytecode(src)
def test_parse_prolix_desc(prolix_desc): ret = parse_bytecode(prolix_desc)
def test_parse_badline_syntaxerror(badline): with pytest.raises(SyntaxError): ret = parse_bytecode(badline)
def test_parse_add_fragment_opname(add_fragment): ret = parse_bytecode(add_fragment) ret[2].opname == "BINARY_ADD"
def test_parse_add_fragment_offset(add_fragment): ret = parse_bytecode(add_fragment) ret[3].offset == 7
def test_parse_add_fragment_lineno(add_fragment): ret = parse_bytecode(add_fragment) ret[1].lineno == 2