File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -1842,6 +1842,32 @@ elif run_os == 'wasi':
1842
1842
config .target_sdk_name = "wasi"
1843
1843
config .target_runtime = "native"
1844
1844
1845
+ # Exclude test cases that use objc-interop because clang doesn't support it
1846
+ # with WebAssembly binary file yet.
1847
+ def use_objc_interop (path ):
1848
+ try :
1849
+ with open (path ) as f :
1850
+ return '-enable-objc-interop' in f .read ()
1851
+ except :
1852
+ return False
1853
+ def lldb_related_test (path ):
1854
+ try :
1855
+ with open (path ) as f :
1856
+ return 'lldb-moduleimport-test' in f .read ()
1857
+ except :
1858
+ return False
1859
+
1860
+ def disabled_filenames (path ):
1861
+ matches = []
1862
+ for root , dirnames , filenames in os .walk (path ):
1863
+ for filename in filenames :
1864
+ filepath = os .path .join (root , filename )
1865
+ if use_objc_interop (filepath ) or lldb_related_test (filepath ):
1866
+ matches .append (os .path .basename (filepath ))
1867
+ return matches
1868
+
1869
+ config .excludes += disabled_filenames (config .test_source_root )
1870
+
1845
1871
config .target_swift_autolink_extract = inferSwiftBinary ("swift-autolink-extract" )
1846
1872
1847
1873
config .target_build_swift = ' ' .join ([
You can’t perform that action at this time.
0 commit comments