tests.fetchtorrent: avoid builtins.convertHash
This function wasn't added until Nix 2.19, so we shouldn't (yet) be relying on it.
This commit is contained in:
@@ -62,17 +62,7 @@ let
|
|||||||
# Fixed output derivation hash is identical for all derivations: the empty
|
# Fixed output derivation hash is identical for all derivations: the empty
|
||||||
# directory.
|
# directory.
|
||||||
fetchtorrentWithHash =
|
fetchtorrentWithHash =
|
||||||
args:
|
args: fetchtorrent ({ hash = "sha256-pQpattmS9VmO3ZIQUFn66az8GSmB4IvYhTTCFn6SUmo="; } // args);
|
||||||
fetchtorrent (
|
|
||||||
{
|
|
||||||
hash = builtins.convertHash {
|
|
||||||
hash = emptyDirectory.outputHash;
|
|
||||||
toHashFormat = "sri";
|
|
||||||
hashAlgo = emptyDirectory.outputHashAlgo;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
// args
|
|
||||||
);
|
|
||||||
in
|
in
|
||||||
# Seems almost but not quite worth using lib.mapCartesianProduct...
|
# Seems almost but not quite worth using lib.mapCartesianProduct...
|
||||||
builtins.mapAttrs (n: v: testers.invalidateFetcherByDrvHash fetchtorrentWithHash v) {
|
builtins.mapAttrs (n: v: testers.invalidateFetcherByDrvHash fetchtorrentWithHash v) {
|
||||||
|
|||||||
Reference in New Issue
Block a user