diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index a6963a6ef6f4..badad067fe11 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -1461,6 +1461,7 @@ in shadps4 = runTest ./shadps4.nix; sharkey = runTest ./web-apps/sharkey.nix; shattered-pixel-dungeon = runTest ./shattered-pixel-dungeon.nix; + shelfmark = runTest ./shelfmark.nix; shiori = runTest ./shiori.nix; shoko = import ./shoko.nix { inherit runTest; }; signal-desktop = runTest ./signal-desktop.nix; diff --git a/nixos/tests/shelfmark.nix b/nixos/tests/shelfmark.nix new file mode 100644 index 000000000000..da91edce5f97 --- /dev/null +++ b/nixos/tests/shelfmark.nix @@ -0,0 +1,20 @@ +{ lib, ... }: +{ + name = "shelfmark"; + meta.maintainers = with lib.maintainers; [ jamiemagee ]; + + nodes.machine = { + services.shelfmark = { + enable = true; + environment.FLASK_HOST = "0.0.0.0"; + }; + }; + + testScript = '' + machine.wait_for_unit("shelfmark.service") + machine.wait_for_open_port(8084) + + with subtest("Health endpoint responds"): + machine.succeed("curl --fail http://localhost:8084/api/health") + ''; +}