Skip to content

Commit 83a8c39

Browse files
committed
test_bug_1333982(): This one must fail under -O.
All the --all test pass using -O on WinXP now.
1 parent 903a944 commit 83a8c39

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Lib/test/test_dis.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,10 @@ def test_bug_708901(self):
121121
self.do_disassembly_test(bug708901, dis_bug708901)
122122

123123
def test_bug_1333982(self):
124-
self.do_disassembly_test(bug1333982, dis_bug1333982)
124+
# This one is checking bytecodes generated for an `assert` statement,
125+
# so fails if the tests are run with -O. Skip this test then.
126+
if __debug__:
127+
self.do_disassembly_test(bug1333982, dis_bug1333982)
125128

126129
def test_main():
127130
run_unittest(DisTests)

0 commit comments

Comments
 (0)