Loading nixos/tests/all-tests.nix +1 −0 Original line number Diff line number Diff line Loading @@ -834,6 +834,7 @@ in kimai = runTest ./kimai.nix; kismet = runTest ./kismet.nix; kmonad = runTest ./kmonad.nix; kmscon = runTest ./kmscon.nix; knot = runTest ./knot.nix; komga = runTest ./komga.nix; komodo-periphery = runTest ./komodo-periphery.nix; Loading nixos/tests/kmscon.nix 0 → 100644 +43 −0 Original line number Diff line number Diff line { ... }: { name = "kmscon"; nodes.machine = { pkgs, lib, ... }: { imports = [ ./common/user-account.nix ]; services.kmscon = { enable = true; hwRender = true; fonts = [ { name = "JetBrainsMono Nerd Font"; package = pkgs.nerd-fonts.jetbrains-mono; } ]; package = pkgs.kmscon; }; }; enableOCR = true; testScript = '' machine.succeed(":") # ^ this create a screen with subtest("ensure we can open a tty"): machine.wait_for_text("machine login:") machine.send_chars("alice\n") machine.wait_for_text("Password:") machine.send_chars("foobar\n") machine.wait_for_text("alice@machine") machine.screenshot("tty.png") ''; } Loading
nixos/tests/all-tests.nix +1 −0 Original line number Diff line number Diff line Loading @@ -834,6 +834,7 @@ in kimai = runTest ./kimai.nix; kismet = runTest ./kismet.nix; kmonad = runTest ./kmonad.nix; kmscon = runTest ./kmscon.nix; knot = runTest ./knot.nix; komga = runTest ./komga.nix; komodo-periphery = runTest ./komodo-periphery.nix; Loading
nixos/tests/kmscon.nix 0 → 100644 +43 −0 Original line number Diff line number Diff line { ... }: { name = "kmscon"; nodes.machine = { pkgs, lib, ... }: { imports = [ ./common/user-account.nix ]; services.kmscon = { enable = true; hwRender = true; fonts = [ { name = "JetBrainsMono Nerd Font"; package = pkgs.nerd-fonts.jetbrains-mono; } ]; package = pkgs.kmscon; }; }; enableOCR = true; testScript = '' machine.succeed(":") # ^ this create a screen with subtest("ensure we can open a tty"): machine.wait_for_text("machine login:") machine.send_chars("alice\n") machine.wait_for_text("Password:") machine.send_chars("foobar\n") machine.wait_for_text("alice@machine") machine.screenshot("tty.png") ''; }