Commit c4003283 authored by Ivan Mincik's avatar Ivan Mincik
Browse files

devenv: add version test

parent eb1beb49
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
, fetchFromGitHub
, makeWrapper
, rustPlatform
, testers

, cachix
, darwin
@@ -10,6 +11,8 @@
, nix
, openssl
, pkg-config

, devenv  # required to run version test
}:

let
@@ -50,6 +53,13 @@ in rustPlatform.buildRustPackage {
    wrapProgram $out/bin/devenv --set DEVENV_NIX ${devenv_nix} --prefix PATH ":" "$out/bin:${cachix}/bin"
  '';

  passthru.tests = {
    version = testers.testVersion {
      package = devenv;
      command = "export XDG_DATA_HOME=$PWD; devenv version";
    };
  };

  meta = {
    changelog = "https://github.com/cachix/devenv/releases/tag/v${version}";
    description = "Fast, Declarative, Reproducible, and Composable Developer Environments";