Skip to content

Commit

Permalink
Disable compiler tests that exceed Bytecode DSL size limits
Browse files Browse the repository at this point in the history
  • Loading branch information
DSouzaM committed Jun 3, 2024
1 parent 3163276 commit 749358b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion graalpython/lib-python/3/test/support/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1062,7 +1062,7 @@ def bytecode_dsl_excluded(test):
"""
try:
if sys.implementation.name == 'graalpy' and __graalpython__.is_bytecode_dsl_interpreter:
return unittest.skip("implementation detail not available on the Bytecode DSL interpreter")
return unittest.skip("Not supported by the Bytecode DSL interpreter")
except NameError:
pass
return test
Expand Down
5 changes: 4 additions & 1 deletion graalpython/lib-python/3/test/test_compile.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import types
import textwrap
from test import support
from test.support import script_helper, requires_debug_ranges, impl_detail
from test.support import script_helper, requires_debug_ranges, impl_detail, bytecode_dsl_excluded
from test.support.os_helper import FakePath


Expand Down Expand Up @@ -108,6 +108,7 @@ def __getitem__(self, key):
exec('z = a', g, d)
self.assertEqual(d['z'], 12)

@bytecode_dsl_excluded
def test_extended_arg(self):
# default: 1000 * 2.5 = 2500 repetitions
repeat = int(sys.getrecursionlimit() * 2.5)
Expand Down Expand Up @@ -770,6 +771,7 @@ def test_path_like_objects(self):
compile("42", FakePath("test_compile_pathlike"), "single")

@support.requires_resource('cpu')
@bytecode_dsl_excluded
def test_stack_overflow(self):
# bpo-31113: Stack overflow when compile a long sequence of
# complex statements.
Expand Down Expand Up @@ -1019,6 +1021,7 @@ async def test(aseq):
code_lines = self.get_code_lines(test.__code__)
self.assertEqual(expected_lines, code_lines)

@bytecode_dsl_excluded
def test_big_dict_literal(self):
# The compiler has a flushing point in "compiler_dict" that calls compiles
# a portion of the dictionary literal when the loop that iterates over the items
Expand Down

0 comments on commit 749358b

Please sign in to comment.