Skip to content

Commit 07c1b90

Browse files
committed
more tests
1 parent 6f01050 commit 07c1b90

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

test/test_other.py

+14-4
Original file line numberDiff line numberDiff line change
@@ -10275,20 +10275,30 @@ def verify_features_sec(feature, expect_in):
1027510275
else:
1027610276
self.assertFalse(feature in features)
1027710277

10278-
def compile(flag):
10279-
self.run_process([EMCC, test_file('hello_world.c'), '-c', flag])
10278+
def compile(flags):
10279+
self.run_process([EMCC, test_file('hello_world.c'), '-c'] + flags)
1028010280

10281-
compile('')
10281+
compile([])
1028210282
verify_features_sec('bulk-memory', False)
1028310283
verify_features_sec('nontrapping-fptoint', False)
1028410284
verify_features_sec('sign-ext', True)
1028510285
verify_features_sec('mutable-globals', True)
1028610286
verify_features_sec('multivalue', True)
10287+
verify_features_sec('reference-types', True)
1028710288

10288-
compile('-sMIN_SAFARI_VERSION=150000')
10289+
compile(['-mnontrapping-fptoint'])
10290+
verify_features_sec('nontrapping-fptoint', True)
10291+
10292+
compile(['-sMIN_SAFARI_VERSION=150000'])
10293+
verify_features_sec('sign-ext', True)
10294+
verify_features_sec('mutable-globals', True)
10295+
verify_features_sec('multivalue', True)
1028910296
verify_features_sec('bulk-memory', True)
1029010297
verify_features_sec('nontrapping-fptoint', True)
1029110298

10299+
compile(['-sMIN_SAFARI_VERSION=150000', '-mno-bulk-memory'])
10300+
verify_features_sec('bulk-memory', False)
10301+
1029210302
def test_js_preprocess(self):
1029310303
# Use stderr rather than stdout here because stdout is redirected to the output JS file itself.
1029410304
create_file('lib.js', '''

0 commit comments

Comments
 (0)