From 2f44a729c2d044720a4e4f603214a46490be5965 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20=E2=80=9CNiols=E2=80=9D=20Jeannerod?= Date: Mon, 9 Sep 2024 14:08:12 +0200 Subject: [PATCH] Follow things graphically --- garage.nix | 2 +- tests/pixelfed-garage.nix | 20 ++++++++++++++++++-- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/garage.nix b/garage.nix index 61d729a9..944c7f92 100644 --- a/garage.nix +++ b/garage.nix @@ -173,7 +173,7 @@ in { script = '' set -xeuo pipefail # give garage time to start up - sleep 3 + sleep 60 # XXX: this is very sensitive to being a single instance # (doing the bare minimum to get garage up and running) diff --git a/tests/pixelfed-garage.nix b/tests/pixelfed-garage.nix index b06c438b..2431ef80 100644 --- a/tests/pixelfed-garage.nix +++ b/tests/pixelfed-garage.nix @@ -24,10 +24,10 @@ let # the “Create New Post” button is visible. print("Create and configure driver...") options = Options() - options.add_argument("--headless=new") + # options.add_argument("--headless=new") service = webdriver.ChromeService(executable_path="${lib.getExe pkgs.chromedriver}") # noqa: E501 driver = webdriver.Chrome(options=options, service=service) - driver.implicitly_wait(10) + driver.implicitly_wait(30) driver.set_window_size(1280, 960) # FIXME: Replace the By.XPATH by By.CSS_SELECTOR. @@ -78,6 +78,22 @@ pkgs.nixosTest { nodes = { server = { config, ... }: { + + services = { + xserver = { + enable = true; + displayManager.lightdm.enable = true; + desktopManager.lxqt.enable = true; + }; + + displayManager.autoLogin = { + enable = true; + user = "selenium"; + }; + }; + virtualisation.resolution = { x = 1680; y = 1050; }; + + virtualisation = { memorySize = lib.mkVMOverride 8192; cores = 8;