Skip to content

Commit b378e48

Browse files
committed
Remove outdated test
1 parent 36c91b0 commit b378e48

File tree

1 file changed

+0
-23
lines changed

1 file changed

+0
-23
lines changed

tests/nixos/fetchers-substitute.nix

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -149,28 +149,5 @@
149149
content = importer.succeed(f"cat {result_path}/hello.txt").strip()
150150
assert content == "Hello from tarball!", f"Content mismatch: {content}"
151151
print("✓ fetchTarball content verified!")
152-
153-
##########################################
154-
# Test 3: Verify fetchTree does NOT substitute (preserves metadata)
155-
##########################################
156-
157-
print("Testing that fetchTree without __final does NOT use substitution...")
158-
159-
# fetchTree with just narHash (not __final) should try to download, which will fail
160-
# since the file doesn't exist on the importer
161-
exit_code = importer.fail(f"""
162-
nix-instantiate --eval --json --read-write-mode --expr '
163-
builtins.fetchTree {{
164-
type = "tarball";
165-
url = "file:///only-on-substituter.tar.gz";
166-
narHash = "{tarball_hash_sri}";
167-
}}
168-
' 2>&1
169-
""")
170-
171-
# Should fail with "does not exist" since it tries to download instead of substituting
172-
assert "does not exist" in exit_code or "Couldn't open file" in exit_code, f"Expected download failure, got: {exit_code}"
173-
print("✓ fetchTree correctly does NOT substitute non-final inputs!")
174-
print(" (This preserves metadata like lastModified from the actual fetch)")
175152
'';
176153
}

0 commit comments

Comments
 (0)