diff options
author | John Ericson <John.Ericson@Obsidian.Systems> | 2022-03-25 16:46:28 +0000 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2022-03-25 16:48:50 +0000 |
commit | 0966532dc15485f24080e868f0c0553b5dc762c9 (patch) | |
tree | 4c3b0f31331b0588133bbbd0083adc85450fcc46 /tests/user-envs.sh | |
parent | e5c42bba9bf76d00fb15ec9a179bf91aa81c38c6 (diff) | |
parent | 1844172dd16cab611a0148be9381ab856bf241df (diff) |
Merge remote-tracking branch 'upstream' into indexed-store-path-outputs
Co-Authored-By: Tom Bereknyei <tomberek@gmail.com>
Diffstat (limited to 'tests/user-envs.sh')
-rw-r--r-- | tests/user-envs.sh | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/user-envs.sh b/tests/user-envs.sh index 430688de1..d63fe780a 100644 --- a/tests/user-envs.sh +++ b/tests/user-envs.sh @@ -17,6 +17,16 @@ outPath10=$(nix-env -f ./user-envs.nix -qa --out-path --no-name '*' | grep foo-1 drvPath10=$(nix-env -f ./user-envs.nix -qa --drv-path --no-name '*' | grep foo-1.0) [ -n "$outPath10" -a -n "$drvPath10" ] +# Query with json +nix-env -f ./user-envs.nix -qa --json | jq -e '.[] | select(.name == "bar-0.1") | [ + .outputName == "out", + .outputs.out == null +] | all' +nix-env -f ./user-envs.nix -qa --json --out-path | jq -e '.[] | select(.name == "bar-0.1") | [ + .outputName == "out", + (.outputs.out | test("'$NIX_STORE_DIR'.*-0\\.1")) +] | all' + # Query descriptions. nix-env -f ./user-envs.nix -qa '*' --description | grep -q silly rm -rf $HOME/.nix-defexpr |