nyxt: init nixos test (#427912)

Changed files
+38
nixos
pkgs
applications
networking
browsers
+1
nixos/tests/all-tests.nix
···
ntpd-rs = runTest ./ntpd-rs.nix;
nvidia-container-toolkit = runTest ./nvidia-container-toolkit.nix;
nvmetcfg = runTest ./nvmetcfg.nix;
+
nyxt = runTest ./nyxt.nix;
nzbget = runTest ./nzbget.nix;
nzbhydra2 = runTest ./nzbhydra2.nix;
ocis = runTest ./ocis.nix;
+35
nixos/tests/nyxt.nix
···
+
{
+
pkgs,
+
lib,
+
...
+
}:
+
{
+
name = "nyxt";
+
+
meta.maintainers = with lib.maintainers; [ ethancedwards8 ];
+
+
nodes.machine = {
+
imports = [
+
# sets up x11 with autologin
+
./common/x11.nix
+
];
+
+
environment.systemPackages = with pkgs; [ nyxt ];
+
+
# not enough memory for the allocation
+
virtualisation.memorySize = 2048;
+
};
+
+
enableOCR = true;
+
+
testScript =
+
{ nodes, ... }:
+
''
+
start_all()
+
machine.wait_for_x()
+
+
with subtest("Wait until Nyxt has finished loading the Valgrind docs page"):
+
machine.execute("xterm -e 'nyxt file://${pkgs.valgrind.doc}/share/doc/valgrind/html/index.html' >&2 &");
+
machine.wait_for_window("nyxt")
+
'';
+
}
+2
pkgs/applications/networking/browsers/nyxt/default.nix
···
xclip,
wl-clipboard,
nix-update-script,
+
nixosTests,
}:
stdenv.mkDerivation (finalAttrs: {
···
passthru = {
tests.version = testers.testVersion { package = finalAttrs.finalPackage; };
updateScript = nix-update-script { };
+
tests = { inherit (nixosTests) nyxt; };
};
meta = with lib; {