diff options
author | Thiago Kenji Okada <thiagokokada@gmail.com> | 2021-01-19 11:33:01 -0300 |
---|---|---|
committer | Thiago Kenji Okada <thiagokokada@gmail.com> | 2021-01-19 14:05:48 -0300 |
commit | 313ee6bd963a2136479c30199e97f1e942eee003 (patch) | |
tree | 7a177d6b054513b12af0b2ade6d0bfeb52dea733 /nixos/tests | |
parent | 98873022d4265c8ed77b1e2942c46ebea5afd93a (diff) |
opentabletdriver: 0.4.2 -> 0.5.0
Diffstat (limited to 'nixos/tests')
-rw-r--r-- | nixos/tests/opentabletdriver.nix | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/nixos/tests/opentabletdriver.nix b/nixos/tests/opentabletdriver.nix index 832d4c25a540..fe345a7bec73 100644 --- a/nixos/tests/opentabletdriver.nix +++ b/nixos/tests/opentabletdriver.nix @@ -1,4 +1,6 @@ -import ./make-test-python.nix ( { pkgs, ... }: { +import ./make-test-python.nix ( { pkgs, ... }: let + testUser = "alice"; +in { name = "opentabletdriver"; meta = { maintainers = with pkgs.lib.maintainers; [ thiagokokada ]; @@ -10,7 +12,7 @@ import ./make-test-python.nix ( { pkgs, ... }: { ./common/user-account.nix ./common/x11.nix ]; - test-support.displayManager.auto.user = "alice"; + test-support.displayManager.auto.user = testUser; hardware.opentabletdriver.enable = true; }; @@ -18,10 +20,11 @@ import ./make-test-python.nix ( { pkgs, ... }: { '' machine.start() machine.wait_for_x() - machine.wait_for_unit("opentabletdriver.service", "alice") + machine.wait_for_unit("opentabletdriver.service", "${testUser}") - machine.succeed("cat /etc/udev/rules.d/30-opentabletdriver.rules") + machine.succeed("cat /etc/udev/rules.d/99-opentabletdriver.rules") # Will fail if service is not running - machine.succeed("otd detect") + # Needs to run as the same user that started the service + machine.succeed("su - ${testUser} -c 'otd detect'") ''; }) |