1{ runCommand, vega-lite }:
2
3let
4 inherit (vega-lite) packageName version;
5in
6
7runCommand "${packageName}-tests" { meta.timeout = 60; } ''
8 # get version of installed program and compare with package version
9 claimed_version="$(${vega-lite}/bin/vl2vg --version)"
10 if [[ "$claimed_version" != "${version}" ]]; then
11 echo "Error: program version does not match package version ($claimed_version != ${version})"
12 exit 1
13 fi
14
15 # run dummy commands
16 ${vega-lite}/bin/vl2vg --help > /dev/null
17 ${vega-lite}/bin/vl2svg --help > /dev/null
18 ${vega-lite}/bin/vl2png --help > /dev/null
19 ${vega-lite}/bin/vl2pdf --help > /dev/null
20
21 # needed for Nix to register the command as successful
22 touch $out
23''