summary refs log tree commit diff
path: root/nixos/tests/lsd.nix
diff options
context:
space:
mode:
authorTim Steinbach <tim@nequissimus.com>2020-11-28 13:19:46 -0500
committerTim Steinbach <tim@nequissimus.com>2020-11-28 13:42:36 -0500
commit2d85247086e1d870472602291a60a13cf445e6fa (patch)
tree18eb944d7d650f7a76a181e337f83fbb9b12e5b4 /nixos/tests/lsd.nix
parentba3ad059302c6ca9277e298625f585828fb5bddf (diff)
downloadnixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar.gz
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar.bz2
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar.lz
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar.xz
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.tar.zst
nixpkgs-2d85247086e1d870472602291a60a13cf445e6fa.zip
lsd: Add test
Diffstat (limited to 'nixos/tests/lsd.nix')
-rw-r--r--nixos/tests/lsd.nix12
1 files changed, 12 insertions, 0 deletions
diff --git a/nixos/tests/lsd.nix b/nixos/tests/lsd.nix
new file mode 100644
index 00000000000..fee8e95e14f
--- /dev/null
+++ b/nixos/tests/lsd.nix
@@ -0,0 +1,12 @@
+import ./make-test-python.nix ({ pkgs, ... }: {
+  name = "lsd";
+  meta = with pkgs.stdenv.lib.maintainers; { maintainers = [ nequissimus ]; };
+
+  nodes.lsd = { pkgs, ... }: { environment.systemPackages = [ pkgs.lsd ]; };
+
+  testScript = ''
+    lsd.succeed('echo "abc" > /tmp/foo')
+    assert "4 B /tmp/foo" in lsd.succeed('lsd --classic --blocks "size,name" /tmp/foo')
+    assert "lsd ${pkgs.lsd.version}" in lsd.succeed("lsd --version")
+  '';
+})