aboutsummaryrefslogtreecommitdiff
path: root/build2/test/script/parser.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'build2/test/script/parser.cxx')
-rw-r--r--build2/test/script/parser.cxx12
1 files changed, 10 insertions, 2 deletions
diff --git a/build2/test/script/parser.cxx b/build2/test/script/parser.cxx
index da072dc..f250d27 100644
--- a/build2/test/script/parser.cxx
+++ b/build2/test/script/parser.cxx
@@ -2,11 +2,11 @@
// copyright : Copyright (c) 2014-2017 Code Synthesis Ltd
// license : MIT; see accompanying LICENSE file
+#include <build2/test/script/parser>
+
#include <sstream>
#include <cstring> // strstr()
-#include <build2/test/script/parser>
-
#include <build2/scheduler>
#include <build2/test/script/lexer>
@@ -2743,6 +2743,14 @@ namespace build2
for (unique_ptr<scope>& chain: g->scopes)
{
+ // Check if this scope is ignored (e.g., via config.test).
+ //
+ if (!runner_->test (*chain))
+ {
+ chain.reset ();
+ continue;
+ }
+
// Pick a scope from the if-else chain.
//
// In fact, we are going to drop all but the selected (if any)