diff options
Diffstat (limited to 'pkgs/test/texlive')
-rw-r--r-- | pkgs/test/texlive/default.nix | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/pkgs/test/texlive/default.nix b/pkgs/test/texlive/default.nix index 704e277312f25..e2c714100f903 100644 --- a/pkgs/test/texlive/default.nix +++ b/pkgs/test/texlive/default.nix @@ -384,9 +384,10 @@ rec { noArg = [ "a2ping" "bg5+latex" "bg5+pdflatex" "bg5latex" "bg5pdflatex" "cef5latex" "cef5pdflatex" "ceflatex" "cefpdflatex" "cefslatex" "cefspdflatex" "chkdvifont" "dvi2fax" "dvired" "dviselect" "dvitodvi" "epsffit" "findhyph" "gbklatex" "gbkpdflatex" "komkindex" "kpsepath" "listbib" "listings-ext" "mag" "mathspic" "mf2pt1" - "mk4ht" "mkt1font" "mkgrkindex" "musixflx" "pdf2ps" "pdftosrc" "pdfxup" "pedigree" "pfb2pfa" "pk2bm" "prepmx" - "ps2pk" "psselect" "pstops" "rubibtex" "rubikrotation" "sjislatex" "sjispdflatex" "srcredact" "t4ht" "tex4ht" - "texdiff" "texdirflatten" "texplate" "tie" "ttf2kotexfont" "ttfdump" "vlna" "vpl2ovp" "vpl2vpl" "yplan" ]; + "mk4ht" "mkt1font" "mkgrkindex" "musixflx" "pdf2ps" "pdfclose" "pdftosrc" "pdfxup" "pedigree" "pfb2pfa" "pk2bm" + "prepmx" "ps2pk" "psselect" "pstops" "rubibtex" "rubikrotation" "sjislatex" "sjispdflatex" "srcredact" "t4ht" + "teckit_compile" "tex4ht" "texdiff" "texdirflatten" "texplate" "tie" "ttf2kotexfont" "ttfdump" "vlna" "vpl2ovp" + "vpl2vpl" "yplan" ]; # (3) binaries requiring a .tex file contextTest = [ "htcontext" ]; latexTest = [ "de-macro" "e2pall" "htlatex" "htxelatex" "makeindex" "pslatex" "rumakeindex" "tpic2pdftex" @@ -642,4 +643,25 @@ rec { echo "$errorText" false ''); + + # verify that all fixed hashes are present + # this is effectively an eval-time assertion, converted into a derivation for + # ease of testing + fixedHashes = with lib; let + combine = findFirst (p: (head p.pkgs).pname == "combine") { pkgs = []; } (head texlive.collection-latexextra.pkgs).tlDeps; + all = concatLists (map (p: p.pkgs or []) (attrValues (removeAttrs texlive [ "bin" "combine" "combined" "tlpdb" ]))) ++ combine.pkgs; + fods = filter (p: isDerivation p && p.tlType != "bin") all; + errorText = concatMapStrings (p: optionalString (! p ? outputHash) "${p.pname + optionalString (p.tlType != "run") ("." + p.tlType)} does not have a fixed output hash\n") fods; + in runCommand "texlive-test-fixed-hashes" { + inherit errorText; + passAsFile = [ "errorText" ]; + } '' + if [[ -s "$errorTextPath" ]] ; then + cat "$errorTextPath" + echo Failed: some TeX Live packages do not have fixed output hashes. Please read UPGRADING.md for how to generate a new fixed-hashes.nix. + exit 1 + else + touch "$out" + fi + ''; } |