Skip to content

Commit ce482c5

Browse files
Fix test
1 parent 5f03d23 commit ce482c5

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Lib/test/test_capi/test_opt.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3303,9 +3303,8 @@ def testfunc(n):
33033303
uops = get_opnames(ex)
33043304

33053305
self.assertIn("_FOR_ITER_GEN_FRAME", uops)
3306-
self.assertIn("_YIELD_VALUE", uops)
33073306
# _POP_TOP_NOP is a sign the optimizer ran and didn't hit bottom.
3308-
self.assertGreaterEqual(count_ops(ex, "_POP_TOP_NOP"), 3)
3307+
self.assertGreaterEqual(count_ops(ex, "_POP_TOP_NOP"), 1)
33093308

33103309
def test_send_gen_frame(self):
33113310

@@ -3327,10 +3326,9 @@ def testfunc(n):
33273326
uops = get_opnames(ex)
33283327

33293328
self.assertIn("_FOR_ITER_GEN_FRAME", uops)
3330-
self.assertIn("_YIELD_VALUE", uops)
33313329
self.assertIn("_SEND_GEN_FRAME", uops)
33323330
# _POP_TOP_NOP is a sign the optimizer ran and didn't hit bottom.
3333-
self.assertGreaterEqual(count_ops(ex, "_POP_TOP_NOP"), 2)
3331+
self.assertGreaterEqual(count_ops(ex, "_POP_TOP_NOP"), 1)
33343332

33353333
def test_143026(self):
33363334
# https://github.com/python/cpython/issues/143026

0 commit comments

Comments
 (0)