ktest: Add IF and ELSE to config sections
authorSteven Rostedt <srostedt@redhat.com>
Fri, 30 Sep 2011 23:44:53 +0000 (19:44 -0400)
committerSteven Rostedt <rostedt@goodmis.org>
Mon, 17 Oct 2011 15:54:11 +0000 (11:54 -0400)
commit45d73a5d8a98dbabcdf37e2da5ef5b0412244643
tree171cebe896512759e763a9d7bb36efe43455d1d1
parent4ab1cce5bdd87948b75ed4fe4a8629c0f76267ae
ktest: Add IF and ELSE to config sections

Add IF keyword to sections within the config. Also added an ELSE
keyword that allows different config options to be set for a given
section.

For example:

TYPE := 1
STATUS := 0

DEFAULTS IF ${TYPE}
[...]
ELSE IF ${STATUS}
[...]
ELSE
[...]

The above will process the first section as $TYPE is true. If it
was false, it would process the last section as $STATUS is false.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
tools/testing/ktest/ktest.pl
tools/testing/ktest/sample.conf