forked from lix-project/lix
Add some tests for nix store ping
Always good to have :)
This commit is contained in:
parent
4f24a33d34
commit
d139474f48
|
@ -62,6 +62,7 @@ nix_tests = \
|
||||||
ca/nix-copy.sh \
|
ca/nix-copy.sh \
|
||||||
eval-store.sh \
|
eval-store.sh \
|
||||||
readfile-context.sh \
|
readfile-context.sh \
|
||||||
|
store-ping.sh \
|
||||||
why-depends.sh
|
why-depends.sh
|
||||||
# parallel.sh
|
# parallel.sh
|
||||||
|
|
||||||
|
|
12
tests/store-ping.sh
Normal file
12
tests/store-ping.sh
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
source common.sh
|
||||||
|
|
||||||
|
STORE_INFO=$(nix store ping 2>&1)
|
||||||
|
|
||||||
|
echo "$STORE_INFO" | grep "Store URL: ${NIX_REMOTE}"
|
||||||
|
|
||||||
|
if isDaemonNewer "2.7pre20220126"; then
|
||||||
|
echo "$STORE_INFO" | grep "Version: $($NIX_DAEMON_PACKAGE/bin/nix-daemon --version)"
|
||||||
|
fi
|
||||||
|
|
||||||
|
expect 127 NIX_REMOTE=unix:$PWD/store nix store ping || \
|
||||||
|
fail "nix store ping on a non-existent store should fail"
|
Loading…
Reference in a new issue