1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-06 21:41:48 +02:00

Allow running all the tests with the daemon

When `NIX_DAEMON_PACKAGE` is set, make all the tests use the Nix daemon.
That way we can test every piece of Nix functionality both with and
without the daemon.

Tests for which using the daemon isn’t possible or doesn’t make sens can
selectively be disabled with `needLocalStore`
This commit is contained in:
regnat 2021-07-26 06:54:55 +02:00
parent 706777a4a8
commit addacfce4a
25 changed files with 103 additions and 13 deletions

View file

@ -3,11 +3,14 @@
# Only run this if we have an older Nix available
# XXX: This assumes that the `daemon` package is older than the `client` one
if [[ -z "$NIX_DAEMON_PACKAGE" ]]; then
exit 0
exit 99
fi
source common.sh
killDaemon
unset NIX_REMOTE
# Fill the db using the older Nix
PATH_WITH_NEW_NIX="$PATH"
export PATH="$NIX_DAEMON_PACKAGE/bin:$PATH"