Revert "templates: fix tests"

This reverts commit 7ce29938e9.
This commit is contained in:
Qubasa
2025-06-28 22:41:31 +07:00
parent ba19aa8810
commit b14357a4e0
5 changed files with 15 additions and 1 deletions

View File

@@ -35,6 +35,13 @@ def test_create_flake(
cli.run(["machines", "create", "machine1"])
# create a hardware-configuration.nix that doesn't throw an eval error
for patch_machine in ["jon", "sara"]:
(
flake_dir / "machines" / f"{patch_machine}/hardware-configuration.nix"
).write_text("{}")
with capture_output as output:
cli.run(["machines", "list"])
assert "machine1" in output.out
@@ -72,6 +79,13 @@ def test_create_flake_existing_git(
monkeypatch.chdir(flake_dir)
cli.run(["machines", "create", "machine1"])
# create a hardware-configuration.nix that doesn't throw an eval error
for patch_machine in ["jon", "sara"]:
(
flake_dir / "machines" / f"{patch_machine}/hardware-configuration.nix"
).write_text("{}")
with capture_output as output:
cli.run(["machines", "list"])
assert "machine1" in output.out