aboutsummaryrefslogtreecommitdiff
path: root/unit-tests
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2017-01-26 16:01:58 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2017-02-13 12:42:33 +0200
commit93dbdacafb07b674467aa30c4aefd38bb3871601 (patch)
tree6675150a587b560193ef21ae1d334300655e9d8e /unit-tests
parent88f0780e34116c0441a8d8c58b8a8fd9fde4b1f5 (diff)
Add scheduling calls to operation's match()
Diffstat (limited to 'unit-tests')
-rw-r--r--unit-tests/function/buildfile2
-rw-r--r--unit-tests/function/driver.cxx4
-rw-r--r--unit-tests/test/script/parser/driver.cxx11
3 files changed, 9 insertions, 8 deletions
diff --git a/unit-tests/function/buildfile b/unit-tests/function/buildfile
index 27c73d1..3631958 100644
--- a/unit-tests/function/buildfile
+++ b/unit-tests/function/buildfile
@@ -10,7 +10,7 @@ import libs = libbutl%lib{butl}
src = token lexer diagnostics utility variable name b-options types-parsers \
context scope parser target operation rule prerequisite file module function \
functions-builtin functions-path functions-process-path functions-string \
-functions-target-triplet algorithm search dump filesystem \
+functions-target-triplet algorithm search dump filesystem scheduler \
config/{utility init operation}
diff --git a/unit-tests/function/driver.cxx b/unit-tests/function/driver.cxx
index 4fbbdb6..2f605b0 100644
--- a/unit-tests/function/driver.cxx
+++ b/unit-tests/function/driver.cxx
@@ -26,9 +26,7 @@ namespace build2
main (int, char* argv[])
{
init (argv[0], 1); // Fake build system driver, default verbosity.
-
- ulock ml (model);
- reset (ml, strings ()); // No command line variables.
+ reset (strings ()); // No command line variables.
function_family f ("dummy");
diff --git a/unit-tests/test/script/parser/driver.cxx b/unit-tests/test/script/parser/driver.cxx
index 1e959c1..f1e7483 100644
--- a/unit-tests/test/script/parser/driver.cxx
+++ b/unit-tests/test/script/parser/driver.cxx
@@ -142,10 +142,9 @@ namespace build2
{
tracer trace ("main");
- init (argv[0], 1); // Fake build system driver, default verbosity.
- ulock ml (model);
- sched.startup (1); // Serial execution.
- reset (ml, strings ()); // No command line variables.
+ init (argv[0], 1); // Fake build system driver, default verbosity.
+ sched.startup (1); // Serial execution.
+ reset (strings ()); // No command line variables.
bool scope (false);
bool id (false);
@@ -183,6 +182,8 @@ namespace build2
// be absolute. However, the testscript implementation doesn't
// really care.
//
+ ulock ml (model);
+
file& tt (
targets.insert<file> (work,
dir_path (),
@@ -204,6 +205,8 @@ namespace build2
name.leaf ().extension (),
trace));
+ ml.unlock ();
+
tt.path (path ("driver"));
st.path (name);