1 import ./make-test-python.nix ({ pkgs, ...} : {
3 meta = with pkgs.lib.maintainers; {
7 nodes.default = { ... }: {
11 environment.systemPackages = [ pkgs.zsh-history ];
12 programs.zsh.interactiveShellInit = ''
13 source ${pkgs.zsh-history.out}/share/zsh/init.zsh
15 users.users.root.shell = "${pkgs.zsh}/bin/zsh";
20 default.wait_for_unit("multi-user.target")
21 default.wait_until_succeeds("pgrep -f 'agetty.*tty1'")
24 default.wait_until_tty_matches("1", "login: ")
25 default.send_chars("root\n")
26 default.wait_until_tty_matches("1", r"\nroot@default\b")
28 # Generate some history
29 default.send_chars("echo foobar\n")
30 default.wait_until_tty_matches("1", "foobar")
32 # Ensure that command was recorded in history
33 default.succeed("/run/current-system/sw/bin/history list | grep -q foobar")