diff options
author | Tim Steinbach <tim@nequissimus.com> | 2020-12-29 11:13:26 -0500 |
---|---|---|
committer | Tim Steinbach <NeQuissimus@users.noreply.github.com> | 2021-01-02 15:43:01 -0500 |
commit | 4c9414d31c6a88b599716a057d86d55f40299af9 (patch) | |
tree | 88b75be3180f7f0655ab4f6afb65e28baa864158 /nixos | |
parent | 0576111e8ae62ae19cc5b1908e87bd3e34a22bc0 (diff) |
hub: Add test
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/tests/all-tests.nix | 1 | ||||
-rw-r--r-- | nixos/tests/git/hub.nix | 17 |
2 files changed, 18 insertions, 0 deletions
diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index 659e538b31d0..c491b559213c 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -158,6 +158,7 @@ in home-assistant = handleTest ./home-assistant.nix {}; hostname = handleTest ./hostname.nix {}; hound = handleTest ./hound.nix {}; + hub = handleTest ./git/hub.nix {}; hydra = handleTest ./hydra {}; i3wm = handleTest ./i3wm.nix {}; icingaweb2 = handleTest ./icingaweb2.nix {}; diff --git a/nixos/tests/git/hub.nix b/nixos/tests/git/hub.nix new file mode 100644 index 000000000000..e2359e887efb --- /dev/null +++ b/nixos/tests/git/hub.nix @@ -0,0 +1,17 @@ +import ../make-test-python.nix ({ pkgs, ...} : { + name = "hub"; + meta = with pkgs.stdenv.lib.maintainers; { + maintainers = [ nequissimus ]; + }; + + nodes.hub = { pkgs, ... }: + { + environment.systemPackages = [ pkgs.gitAndTools.hub ]; + }; + + testScript = + '' + assert "git version ${pkgs.git.version}\nhub version ${pkgs.gitAndTools.hub.version}\n" in hub.succeed("hub version") + assert "These GitHub commands are provided by hub" in hub.succeed("hub help") + ''; +}) |