diff --git a/pyomo/core/tests/unit/test_visitor.py b/pyomo/core/tests/unit/test_visitor.py index b70996a13dc..086c57aa560 100644 --- a/pyomo/core/tests/unit/test_visitor.py +++ b/pyomo/core/tests/unit/test_visitor.py @@ -1822,8 +1822,9 @@ def run_walker(self, walker): cases = [] else: # 3 sufficed through Python 3.10, but appeared to need to be - # raised to 5 for recent 3.11 builds (3.11.2) - cases = [(0, ""), (5, warn_msg)] + # raised to 5 for Python 3.11 builds (3.11.2), and again to + # 10 for Python 3.12 builds (3.12.0) + cases = [(0, ""), (10, warn_msg)] head_room = sys.getrecursionlimit() - get_stack_depth() for n, msg in cases: