diff options
author | Emery Hemingway <emery@dmz.rs> | 2024-09-10T08·30+0300 |
---|---|---|
committer | Emery Hemingway <emery@dmz.rs> | 2024-09-10T08·36+0300 |
commit | 08399c719a67b92ef2ff6afcffc960fd35ae5f99 (patch) | |
tree | 8f8d82ea6accc07b7d4d903b8d99a844b1860627 | |
parent | 39ea7f188a95de2f5c7481009e5e107759abcd3e (diff) |
fix(emery/nix-actor): remove import tests subtree-staging
Cannot reliably import from $NIX_PATH or a path constant. Change-Id: Ic9c3a8d4cd9e22ae1ae6d3955d10905afe391efd
-rw-r--r-- | users/emery/nix-actor/tests/test.nim | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/users/emery/nix-actor/tests/test.nim b/users/emery/nix-actor/tests/test.nim index 5e5fe23f5bac..2041e76f1738 100644 --- a/users/emery/nix-actor/tests/test.nim +++ b/users/emery/nix-actor/tests/test.nim @@ -52,14 +52,6 @@ suite "libexpr": test s: checkConversion(s) - test "derivation": - let samples = [ - "let depot = import /depot { }; in depot.users.emery.pkgs.syndicate-server" - ] - for s in samples: - test s: - checkConversion(s) - test "large": let samples = "builtins.listToAttrs (builtins.genList (x: { name = toString x; value = null; }) 99)" @@ -100,44 +92,3 @@ suite "eval": eval.close() store.close() - -suite "import": - let - store = openStore() - eval = store.newState() - - block: - ## full expression string - let f = eval.evalFromString("false") - let t = eval.evalFromString("true") - let fs = $f.toPreserves(eval) - let ts = $t.toPreserves(eval) - checkpoint "false:", fs - check fs == "#f", fs - check ts == "#t", ts - - block: - ## full expression string - let fn = eval.evalFromString("x: x") - let x = eval.evalFromString("let pkgs = import /home/repo/nixpkgs {}; in pkgs.ncdc.meta.homepage") - eval.force(x) - let y = eval.apply(fn, x) - let pr = $y.toPreserves(eval).unthunkAll - checkpoint "$y.toPreserves(eval):", pr - check pr == """"https://dev.yorhel.nl/ncdc"""" - - block: - ## function - let pre = eval.evalFromString("import /home/repo/nixpkgs") - let args = eval.evalFromString("{ }") - let pkgs = eval.apply(pre, args) - let fn = eval.evalFromString("""pkgs: pkgs.ncdc.meta.homepage""") - let res = eval.apply(fn, pkgs) - let pr = res.toPreserves(eval).unthunkAll - assert not pr.isEmbedded - let text = $pr - checkpoint text - check text == """"https://dev.yorhel.nl/ncdc"""" - - eval.close() - store.close() |