aboutsummaryrefslogtreecommitdiff
path: root/bdep/test.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2018-05-11 15:58:26 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2018-05-11 15:58:26 +0200
commit9a614840171d3b9a169eb57318187ad4e8d9bf17 (patch)
tree2254e0d120abe8cd08716b0aaf39e14e3f82d133 /bdep/test.hxx
parent023f1a286b7dfe80eb80a9e6924e492cf6f3f80a (diff)
Add --immediate|-i and --recursive|-r options to test command
Diffstat (limited to 'bdep/test.hxx')
-rw-r--r--bdep/test.hxx12
1 files changed, 11 insertions, 1 deletions
diff --git a/bdep/test.hxx b/bdep/test.hxx
index b057c24..ff983b2 100644
--- a/bdep/test.hxx
+++ b/bdep/test.hxx
@@ -19,12 +19,22 @@ namespace bdep
const cstrings& pkgs,
const strings& cfg_vars)
{
- run_bpkg (2, o, "test", "-d", c->path, cfg_vars, pkgs);
+ run_bpkg (2,
+ o,
+ "test",
+ "-d", c->path,
+ (o.immediate () ? "--immediate" :
+ o.recursive () ? "--recursive" : nullptr),
+ cfg_vars,
+ pkgs);
}
inline int
cmd_test (const cmd_test_options& o, cli::scanner& args)
{
+ if (o.immediate () && o.recursive ())
+ fail << "both --immediate|-i and --recursive|-r specified";
+
return cmd_build (o, &cmd_test, args);
}
}