This is the long awaited refactor of the NixSettings. It allows one to set, unset and update any and all settings with a neat and easy-to-use interface closes #846 Change-Id: Id4cfb5f853cc1168b506a1f6f405076f3a7cab65
12 lines
409 B
Python
12 lines
409 B
Python
from testlib.fixtures.nix import Nix
|
|
|
|
|
|
# ruff: noqa: N802
|
|
def test_fetchTree_presence(nix: Nix):
|
|
"""Ensures that fetchTree is actually absent if flakes are disabled"""
|
|
nix.settings.add_xp_feature("nix-command")
|
|
assert nix.eval("builtins ? fetchTree", nix.settings).json() is False
|
|
|
|
nix.settings.add_xp_feature("flakes")
|
|
assert nix.eval("builtins ? fetchTree", nix.settings).json() is True
|