Documenting fetchTree is an exercise in frustration because of the sheer amount of stringly typed everything in it. I do not know which fields exist without reading the entirety of libfetchers. However, we can write something slightly perfunctory but at least perhaps somewhat helpful documentation-wise. Fixes: https://git.lix.systems/lix-project/lix/issues/609 Change-Id: I991391b53fcd69172dbc7efb9d384e62bc847b91
11 lines
385 B
Python
11 lines
385 B
Python
from functional2.testlib.fixtures import Nix
|
|
|
|
|
|
def test_fetchTree_presence(nix: Nix):
|
|
"""Ensures that fetchTree is actually absent if flakes are disabled"""
|
|
settings = nix.settings().feature("nix-command")
|
|
assert nix.eval("builtins ? fetchTree", settings).json() == False
|
|
|
|
settings.feature("flakes")
|
|
assert nix.eval("builtins ? fetchTree", settings).json() == True
|