diff --git a/Tests/Functional/lit.cfg b/Tests/Functional/lit.cfg index ad2a048ec..dc0f86b86 100644 --- a/Tests/Functional/lit.cfg +++ b/Tests/Functional/lit.cfg @@ -11,7 +11,7 @@ import os import platform import tempfile - +import sys import lit # Set up lit config. @@ -105,3 +105,6 @@ xctest_checker = os.path.join( 'xctest_checker', 'xctest_checker.py') config.substitutions.append(('%{xctest_checker}', xctest_checker)) + +# Add Python to run xctest_checker.py tests as part of XCTest tests +config.substitutions.append( ('%{python}', sys.executable) ) diff --git a/Tests/Functional/xctest_checker/main.swift b/Tests/Functional/xctest_checker/main.swift new file mode 100644 index 000000000..98ad5807f --- /dev/null +++ b/Tests/Functional/xctest_checker/main.swift @@ -0,0 +1 @@ +// RUN: %{python} -m unittest discover