My personal project and infrastructure archive
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nomicon/pkgs/development/node-packages/package-tests/vega-lite.nix

24 lines
738 B

{ runCommand, vega-lite }:
let
inherit (vega-lite) packageName version;
in
runCommand "${packageName}-tests" { meta.timeout = 60; }
''
# get version of installed program and compare with package version
claimed_version="$(${vega-lite}/bin/vl2vg --version)"
if [[ "$claimed_version" != "${version}" ]]; then
echo "Error: program version does not match package version ($claimed_version != ${version})"
exit 1
fi
# run dummy commands
${vega-lite}/bin/vl2vg --help > /dev/null
${vega-lite}/bin/vl2svg --help > /dev/null
${vega-lite}/bin/vl2png --help > /dev/null
${vega-lite}/bin/vl2pdf --help > /dev/null
# needed for Nix to register the command as successful
touch $out
''