fetchfirefoxaddon: add simple test

This commit is contained in:
Artturin 2021-09-22 05:26:31 +03:00
parent 4f87457314
commit c6b56fbf58
2 changed files with 14 additions and 1 deletions

View File

@ -0,0 +1,10 @@
{ invalidateFetcherByDrvHash, fetchFirefoxAddon, ... }:
{
simple = invalidateFetcherByDrvHash fetchFirefoxAddon {
name = "image-search-options";
# Chosen because its only 147KB
url = "https://addons.mozilla.org/firefox/downloads/file/3059971/image_search_options-3.0.12-fx.xpi";
sha256 = "sha256-H73YWX/DKxvhEwKpWOo7orAQ7c/rQywpljeyxYxv0Gg=";
};
}

View File

@ -506,7 +506,10 @@ with pkgs;
fetchhg = callPackage ../build-support/fetchhg { };
fetchFirefoxAddon = callPackage ../build-support/fetchfirefoxaddon {};
fetchFirefoxAddon = callPackage ../build-support/fetchfirefoxaddon { }
// {
tests = callPackages ../build-support/fetchfirefoxaddon/tests.nix { };
};
# `fetchurl' downloads a file from the network.
fetchurl = if stdenv.buildPlatform != stdenv.hostPlatform