pour the foundations for rpc, and let them set. this is very much unstable and must be opted into with explicit store uris (e.g. by setting `NIX_REMOTE=daemon?protocol=any`). the daemon sockets are not enabled by default and must be enabled with the `rpc-sockets` experimental feature. we will not advertise this just yet because in the current state it one has to be *very* dedicated to the rpc cause to deploy this, but once we have some more bits migrated we may want to add release notes and officially as for beta testing. Co-Authored-By: piegames <git@piegames.de> Change-Id: I85a96ccb700b91190c1eb37154bcc6ae1c03401a
20 lines
696 B
Python
20 lines
696 B
Python
import pytest
|
|
|
|
from testlib.fixtures.nix import Nix, NixDaemon
|
|
|
|
|
|
def test_legacy_sockets_always_appear(nix: Nix, daemon: NixDaemon):
|
|
sockets_dir = nix.env.dirs.nix_state_dir / "daemon-socket"
|
|
with daemon(nix):
|
|
assert sockets_dir.exists()
|
|
assert sockets_dir.is_dir()
|
|
assert (sockets_dir / "socket").exists()
|
|
assert (sockets_dir / "socket").is_socket()
|
|
|
|
|
|
@pytest.mark.parametrize("daemon", ["legacy"], indirect=True)
|
|
def test_xp_sockets_dont_always_appear(nix: Nix, daemon: NixDaemon):
|
|
sockets_dir = nix.env.dirs.nix_state_dir / "daemon-socket"
|
|
with daemon(nix):
|
|
assert list(sockets_dir.glob("./**")) == [sockets_dir, sockets_dir / "socket"]
|