mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-24 02:46:38 +00:00
9153d8ed64
Probably missed a few. Also adding xauth to the system path (it was already in the closure).
34 lines
1 KiB
Nix
34 lines
1 KiB
Nix
import ./make-test.nix ({ pkgs, ...} : {
|
|
name = "i3wm";
|
|
meta = with pkgs.stdenv.lib.maintainers; {
|
|
maintainers = [ aszlig ];
|
|
};
|
|
|
|
machine = { lib, pkgs, ... }: {
|
|
imports = [ ./common/x11.nix ./common/user-account.nix ];
|
|
services.xserver.displayManager.auto.user = "alice";
|
|
services.xserver.windowManager.default = lib.mkForce "i3";
|
|
services.xserver.windowManager.i3.enable = true;
|
|
};
|
|
|
|
testScript = { nodes, ... }: ''
|
|
$machine->waitForX;
|
|
$machine->waitForFile("/home/alice/.Xauthority");
|
|
$machine->succeed("xauth merge ~alice/.Xauthority");
|
|
$machine->waitForWindow(qr/first configuration/);
|
|
$machine->sleep(1);
|
|
$machine->screenshot("started");
|
|
$machine->sendKeys("ret");
|
|
$machine->sleep(1);
|
|
$machine->sendKeys("alt");
|
|
$machine->sleep(1);
|
|
$machine->screenshot("configured");
|
|
$machine->sendKeys("ret");
|
|
$machine->sleep(2);
|
|
$machine->sendKeys("alt-ret");
|
|
$machine->waitForWindow(qr/machine.*alice/);
|
|
$machine->sleep(1);
|
|
$machine->screenshot("terminal");
|
|
'';
|
|
})
|