about summary refs log tree commit diff
path: root/src/libexpr/eval-test.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2010-04-07T13·55+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2010-04-07T13·55+0000
commitfc92244ba81d884e099d467a3b82fbdcbff7fc40 (patch)
treefe66575aab172941946eab41f3974961fe00eb1b /src/libexpr/eval-test.cc
parenta353aef0b157e7c628fd18640bd6c45215f3e606 (diff)
* Implemented the primops necessary for generating the NixOS manual.
Diffstat (limited to 'src/libexpr/eval-test.cc')
-rw-r--r--src/libexpr/eval-test.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/libexpr/eval-test.cc b/src/libexpr/eval-test.cc
index 3399aedc4c8c..eac95094fd1f 100644
--- a/src/libexpr/eval-test.cc
+++ b/src/libexpr/eval-test.cc
@@ -16,7 +16,8 @@ void doTest(string s)
     Expr e = parseExprFromString(state, s, absPath("."));
     printMsg(lvlError, format(">>>>> %1%") % e);
     Value v;
-    state.strictEval(e, v);
+    state.eval(e, v);
+    state.strictForceValue(v);
     printMsg(lvlError, format("result: %1%") % v);
 }
 
@@ -76,6 +77,8 @@ void run(Strings args)
     doTest("let x = 1; as = rec { inherit x; y = as.x; }; in as.y");
     doTest("let as = { x = 1; }; bs = rec { inherit (as) x; y = x; }; in bs.y");
     doTest("let as = rec { inherit (y) x; y = { x = 1; }; }; in as.x");
+    doTest("builtins.toXML 123");
+    doTest("builtins.toXML { a.b = \"x\" + \"y\"; c = [ 1 2 ] ++ [ 3 4 ]; }");
 }