def test_false_while_loop(self):

    def break_in_while():
        while False:
            break

    def continue_in_while():
        while False:
            continue
    funcs = [break_in_while, continue_in_while]
    for func in funcs:
        opcodes = list(dis.get_instructions(func))
        self.assertEqual(3, len(opcodes))
        self.assertEqual('LOAD_CONST', opcodes[1].opname)
        self.assertEqual(None, opcodes[1].argval)
        self.assertEqual('RETURN_VALUE', opcodes[2].opname)
def test_false_while_loop(self):

    def break_in_while():
        while False:
            break

    def continue_in_while():
        while False:
            continue
    funcs = [break_in_while, continue_in_while]
    for func in funcs:
        opcodes = list(dis.get_instructions(func))
        self.assertEqual(3, len(opcodes))
        self.assertEqual('LOAD_CONST', opcodes[1].opname)
        self.assertEqual(None, opcodes[1].argval)
        self.assertEqual('RETURN_VALUE', opcodes[2].opname)