import lit.formats import os config.name = "per-test-coverage" config.suffixes = [".py"] config.test_format = lit.formats.ShTest( execute_external=eval(lit_config.params.get("execute_external")), preamble_commands=["%{python} %s | FileCheck -DINDEX=0 %s"] ) config.substitutions.append(("%{python}", '"%s"' % (sys.executable)))