diff options
author | regnat <rg@regnat.ovh> | 2020-11-10 10:43:33 +0100 |
---|---|---|
committer | regnat <rg@regnat.ovh> | 2021-03-16 14:20:41 +0100 |
commit | 5716345adf2e794fd62229ea52352e74e92e8e63 (patch) | |
tree | 3712c69131d9a84b39cbe4e7f464078fa060af4d /tests/common.sh.in | |
parent | 338f2710580b334a754fad28b88c5cb137c83352 (diff) |
Add a test ensuring compatibility with an old daemon
This requires adding `nix` to its own closure which is a bit unfortunate,
but as it is optional (the test will be disabled if `OUTER_NIX` is unset) it
shouldn't be too much of an issue.
(Ideally this should go in another derivation so that we can build Nix and run
the test independently, but as the tests are running in the same derivation
as the build it's a bit complicated to do so).
Diffstat (limited to 'tests/common.sh.in')
-rw-r--r-- | tests/common.sh.in | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tests/common.sh.in b/tests/common.sh.in index de44a4da4..277dd6dfa 100644 --- a/tests/common.sh.in +++ b/tests/common.sh.in @@ -57,7 +57,6 @@ clearStore() { mkdir "$NIX_STORE_DIR" rm -rf "$NIX_STATE_DIR" mkdir "$NIX_STATE_DIR" - nix-store --init clearProfiles } @@ -73,7 +72,7 @@ startDaemon() { # Start the daemon, wait for the socket to appear. !!! # ‘nix-daemon’ should have an option to fork into the background. rm -f $NIX_STATE_DIR/daemon-socket/socket - nix daemon & + ${NIX_DAEMON_COMMAND:-nix daemon} & for ((i = 0; i < 30; i++)); do if [ -e $NIX_DAEMON_SOCKET_PATH ]; then break; fi sleep 1 |