about summary refs log tree commit diff
path: root/tvix/eval/src/tests/tvix_tests
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2022-08-31T01·47+0300
committertazjin <tazjin@tvl.su>2022-09-07T19·08+0000
commitafcfa7836401d90bbb131b170a3a69b3cf794b1c (patch)
tree50733b76e7595694c0b497ace3f65bab62873c51 /tvix/eval/src/tests/tvix_tests
parent6c6f9ae66123ea3e9e6cdc78bdb55ace712535a1 (diff)
feat(tvix/eval): semi-strictly evaluate output values of the VM r/4705
This essentially makes the VM behave like `nix-instantiate --eval
--strict`, i.e. data structures are traversed strictly and thunks are
forced. Thunks embedded in closures are not forced.

This allows us to re-enable tests that were disabled because they
needed to output nested thunk contents, but is overall a behaviour
that must be configurable later on, as it is not cmopatible with e.g.
an evaluation of nixpkgs.

Change-Id: I5303a5c8e4322feab1384fdb7712fecb950afca5
Reviewed-on: https://cl.tvl.fyi/c/depot/+/6372
Reviewed-by: sterni <sternenseemann@systemli.org>
Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/eval/src/tests/tvix_tests')
-rw-r--r--tvix/eval/src/tests/tvix_tests/disabled-identity-nested-attrs.nix3
-rw-r--r--tvix/eval/src/tests/tvix_tests/identity-nested-attrs.nix1
2 files changed, 1 insertions, 3 deletions
diff --git a/tvix/eval/src/tests/tvix_tests/disabled-identity-nested-attrs.nix b/tvix/eval/src/tests/tvix_tests/disabled-identity-nested-attrs.nix
deleted file mode 100644
index f8dacf3e08..0000000000
--- a/tvix/eval/src/tests/tvix_tests/disabled-identity-nested-attrs.nix
+++ /dev/null
@@ -1,3 +0,0 @@
-# TODO: temporarily disabled because need "strict output" (b is
-# thunked)
-{ a = { b = null; }; }
diff --git a/tvix/eval/src/tests/tvix_tests/identity-nested-attrs.nix b/tvix/eval/src/tests/tvix_tests/identity-nested-attrs.nix
new file mode 100644
index 0000000000..6a139452ef
--- /dev/null
+++ b/tvix/eval/src/tests/tvix_tests/identity-nested-attrs.nix
@@ -0,0 +1 @@
+{ a = { b = null; }; }