From 0a27f400f247dbaaf403b392ce05cb01bf1c9c3f Mon Sep 17 00:00:00 2001 From: Paul Robinson Date: Mon, 4 Apr 2016 17:14:45 +0000 Subject: [PATCH] Document standard substitutions defined by lit. Patch by Guilherme Bufolo! Differential Revision: http://reviews.llvm.org/D18752 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@265314 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/CommandGuide/lit.rst | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/docs/CommandGuide/lit.rst b/docs/CommandGuide/lit.rst index 0ec14bb2236..b2da58ec02c 100644 --- a/docs/CommandGuide/lit.rst +++ b/docs/CommandGuide/lit.rst @@ -355,6 +355,35 @@ be used to define subdirectories of optional tests, or to change other configuration parameters --- for example, to change the test format, or the suffixes which identify test files. +PRE-DEFINED SUBSTITUTIONS +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +:program:`lit` provides various patterns that can be used with the RUN command. +These are defined in TestRunner.py. + + ========== ============== + Macro Substitution + ========== ============== + %s source path (path to the file currently being run) + %S source dir (directory of the file currently being run) + %p same as %S + %{pathsep} path separator + %t temporary file name unique to the test + %T temporary directory unique to the test + %% % + %/s same as %s but replace all / with \\ + %/S same as %S but replace all / with \\ + %/p same as %p but replace all / with \\ + %/t same as %t but replace all / with \\ + %/T same as %T but replace all / with \\ + ========== ============== + +Further substitution patterns might be defined by each test module. +See the modules :ref:`local-configuration-files`. + +More information on the testing infrastucture can be found in the +:doc:`../TestingGuide`. + TEST RUN OUTPUT FORMAT ~~~~~~~~~~~~~~~~~~~~~~ -- 2.11.0