@@ -757,17 +757,6 @@ def update_unittest_tags(args):
757
757
mx .warn ("Potential regressions:\n " + '\n ' .join (x [1 ] for x in diff ))
758
758
759
759
760
- AOT_INCOMPATIBLE_TESTS = ["test_interop.py" , "test_register_interop_behavior.py" , "test_jarray.py" , "test_ssl_java_integration.py" ]
761
- # These test would work on JVM too, but they are prohibitively slow due to a large amount of subprocesses
762
- AOT_ONLY_TESTS = ["test_patched_pip.py" , "test_multiprocessing_spawn.py" ]
763
-
764
- GINSTALL_GATE_PACKAGES = {
765
- "numpy" : "numpy" ,
766
- "scipy" : "scipy" ,
767
- "scikit_learn" : "sklearn" ,
768
- }
769
-
770
-
771
760
class GraalPythonTags (object ):
772
761
junit = 'python-junit'
773
762
junit_maven = 'python-junit-maven'
@@ -1162,7 +1151,7 @@ def is_included(path):
1162
1151
return testfiles
1163
1152
1164
1153
1165
- def run_python_unittests (python_binary , args = None , paths = None , aot_compatible = False , exclude = None , env = None ,
1154
+ def run_python_unittests (python_binary , args = None , paths = None , exclude = None , env = None ,
1166
1155
use_pytest = False , cwd = None , lock = None , out = None , err = None , nonZeroIsFatal = True , timeout = None ,
1167
1156
report = False , parallel = 1 , runner_args = None ):
1168
1157
if lock :
@@ -1175,7 +1164,6 @@ def run_python_unittests(python_binary, args=None, paths=None, aot_compatible=Fa
1175
1164
"--python.EnableDebuggingBuiltins" ,
1176
1165
* args ,
1177
1166
]
1178
- exclude = exclude or []
1179
1167
if env is None :
1180
1168
env = os .environ .copy ()
1181
1169
env ['PYTHONHASHSEED' ] = '0'
@@ -1184,12 +1172,6 @@ def run_python_unittests(python_binary, args=None, paths=None, aot_compatible=Fa
1184
1172
if mx .primary_suite () != SUITE :
1185
1173
env .setdefault ("GRAALPYTEST_ALLOW_NO_JAVA_ASSERTIONS" , "true" )
1186
1174
1187
- # list of excluded tests
1188
- if aot_compatible :
1189
- exclude += AOT_INCOMPATIBLE_TESTS
1190
- else :
1191
- exclude += AOT_ONLY_TESTS
1192
-
1193
1175
# just to be able to verify, print C ext mode (also works for CPython)
1194
1176
mx .run (
1195
1177
[
@@ -1209,8 +1191,9 @@ def run_python_unittests(python_binary, args=None, paths=None, aot_compatible=Fa
1209
1191
if runner_args :
1210
1192
args += runner_args
1211
1193
1212
- for file in exclude :
1213
- args += ['--ignore' , file ]
1194
+ if exclude :
1195
+ for file in exclude :
1196
+ args += ['--ignore' , file ]
1214
1197
1215
1198
if is_collecting_coverage () and mx_gate .get_jacoco_agent_args ():
1216
1199
# jacoco only dumps the data on exit, and when we run all our unittests
@@ -1386,49 +1369,6 @@ def get_wrapper_urls(wrapper_properties_file, keys):
1386
1369
def graalpython_gate_runner (args , tasks ):
1387
1370
report = lambda : (not is_collecting_coverage ()) and task
1388
1371
nonZeroIsFatal = not is_collecting_coverage ()
1389
- if WIN32 :
1390
- # Windows support is still experimental, so we exclude some unittests
1391
- # on Windows for now. If you add unittests and cannot get them to work
1392
- # on Windows, yet, add their files here.
1393
- excluded_tests = [
1394
- "test_code.py" , # forward slash in path problem
1395
- "test_csv.py" ,
1396
- "test_imports.py" , # import posix
1397
- "test_locale.py" ,
1398
- "test_math.py" ,
1399
- "test_memoryview.py" ,
1400
- "test_mmap.py" , # sys.getwindowsversion
1401
- "test_multiprocessing.py" , # import _winapi
1402
- "test_multiprocessing_graalpy.py" , # import _winapi
1403
- "test_patched_pip.py" ,
1404
- "test_pathlib.py" ,
1405
- "test_pdb.py" , # Tends to hit GR-41935
1406
- "test_posix.py" , # import posix
1407
- "test_pyio.py" ,
1408
- "test_signal.py" ,
1409
- "test_struct.py" ,
1410
- "test_structseq.py" , # import posix
1411
- "test_subprocess.py" ,
1412
- "test_thread.py" , # sys.getwindowsversion
1413
- "test_traceback.py" ,
1414
- "test_zipimport.py" , # sys.getwindowsversion
1415
- "test_ssl_java_integration.py" ,
1416
- "cpyext/test_abstract.py" ,
1417
- "cpyext/test_functions.py" ,
1418
- "cpyext/test_long.py" ,
1419
- "cpyext/test_member.py" ,
1420
- "cpyext/test_memoryview.py" ,
1421
- "cpyext/test_misc.py" ,
1422
- "cpyext/test_mmap.py" ,
1423
- "cpyext/test_slice.py" ,
1424
- "cpyext/test_shutdown.py" ,
1425
- "cpyext/test_thread.py" ,
1426
- "cpyext/test_unicode.py" ,
1427
- "cpyext/test_wiki.py" ,
1428
- "cpyext/test_tp_slots.py" , # Temporarily disabled due to GR-54345
1429
- ]
1430
- else :
1431
- excluded_tests = []
1432
1372
1433
1373
# JUnit tests
1434
1374
with Task ('GraalPython JUnit' , tasks , tags = [GraalPythonTags .junit , GraalPythonTags .windows ]) as task :
@@ -1480,7 +1420,6 @@ def graalpython_gate_runner(args, tasks):
1480
1420
if task :
1481
1421
run_python_unittests (
1482
1422
graalpy_standalone_jvm (),
1483
- exclude = excluded_tests ,
1484
1423
nonZeroIsFatal = nonZeroIsFatal ,
1485
1424
report = report ()
1486
1425
)
@@ -1493,11 +1432,11 @@ def graalpython_gate_runner(args, tasks):
1493
1432
1494
1433
with Task ('GraalPython sandboxed tests' , tasks , tags = [GraalPythonTags .unittest_sandboxed ]) as task :
1495
1434
if task :
1496
- run_python_unittests (graalpy_standalone_jvm_enterprise (), args = SANDBOXED_OPTIONS , exclude = excluded_tests , report = report ())
1435
+ run_python_unittests (graalpy_standalone_jvm_enterprise (), args = SANDBOXED_OPTIONS , report = report ())
1497
1436
1498
1437
with Task ('GraalPython multi-context unittests' , tasks , tags = [GraalPythonTags .unittest_multi ]) as task :
1499
1438
if task :
1500
- run_python_unittests (graalpy_standalone_jvm (), args = ["-multi-context" ], exclude = excluded_tests , nonZeroIsFatal = nonZeroIsFatal , report = report ())
1439
+ run_python_unittests (graalpy_standalone_jvm (), args = ["-multi-context" ], nonZeroIsFatal = nonZeroIsFatal , report = report ())
1501
1440
1502
1441
with Task ('GraalPython Jython emulation tests' , tasks , tags = [GraalPythonTags .unittest_jython ]) as task :
1503
1442
if task :
@@ -1577,11 +1516,11 @@ def graalpython_gate_runner(args, tasks):
1577
1516
# Unittests on SVM
1578
1517
with Task ('GraalPython tests on SVM' , tasks , tags = [GraalPythonTags .svmunit , GraalPythonTags .windows ]) as task :
1579
1518
if task :
1580
- run_python_unittests (graalpy_standalone_native (), exclude = excluded_tests , aot_compatible = True , report = report ())
1519
+ run_python_unittests (graalpy_standalone_native (), report = report ())
1581
1520
1582
1521
with Task ('GraalPython sandboxed tests on SVM' , tasks , tags = [GraalPythonTags .svmunit_sandboxed ]) as task :
1583
1522
if task :
1584
- run_python_unittests (graalpy_standalone_native_enterprise (), args = SANDBOXED_OPTIONS , aot_compatible = True , report = report ())
1523
+ run_python_unittests (graalpy_standalone_native_enterprise (), args = SANDBOXED_OPTIONS , report = report ())
1585
1524
1586
1525
with Task ('GraalPython license header update' , tasks , tags = [GraalPythonTags .license ]) as task :
1587
1526
if task :
@@ -2601,13 +2540,13 @@ def python_coverage(args):
2601
2540
]
2602
2541
env ['GRAAL_PYTHON_ARGS' ] = " " .join (extra_args )
2603
2542
# deselect some tagged unittests that hang with coverage enabled
2604
- exclude = [
2543
+ tagged_exclude = [
2605
2544
"test_multiprocessing_spawn" ,
2606
2545
"test_multiprocessing_main_handling" ,
2607
2546
"test_multiprocessing_graalpy" ,
2608
2547
]
2609
2548
if kwds .pop ("tagged" , False ):
2610
- run_tagged_unittests (executable , env = env , nonZeroIsFatal = False , parallel = 1 , exclude = exclude )
2549
+ run_tagged_unittests (executable , env = env , nonZeroIsFatal = False , parallel = 1 , exclude = tagged_exclude )
2611
2550
elif kwds .pop ("hpy" , False ):
2612
2551
run_hpy_unittests (executable , env = env , nonZeroIsFatal = False , timeout = 5 * 60 * 60 ) # hpy unittests are really slow under coverage
2613
2552
else :
0 commit comments