summaryrefslogtreecommitdiffstats
path: root/nixos/tests/servo.nix
blob: 89c3769cd9026b9f17fd6eee55bd77f070478dce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{
  lib,
  pkgs,
  ...
}:
{
  name = "servo";

  meta.maintainers = with lib.maintainers; [ hexa ];

  nodes.machine = {
    imports = [ ./common/x11.nix ];

    environment.systemPackages = with pkgs; [ servo ];
  };

  enableOCR = true;

  testScript = ''
    machine.wait_for_x()

    with subtest("Wait until Servo has finished loading the Valgrind docs page"):
      machine.execute("xterm -e '${lib.getExe pkgs.servo} file://${pkgs.valgrind.doc}/share/doc/valgrind/html/index.html' >&2 &");
      machine.wait_for_window("Valgrind")
      machine.wait_for_text("Quick Start Guide")
  '';

}