From b3082615d990586b1bb7f361e80112ad0848ac6c Mon Sep 17 00:00:00 2001 From: Andrei Pampu Date: Mon, 29 Mar 2021 17:51:05 +0300 Subject: [PATCH] nixos/ombi: add test for ombi to ensure startup --- nixos/tests/all-tests.nix | 1 + nixos/tests/ombi.nix | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) create mode 100644 nixos/tests/ombi.nix diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index 65c7d84ee64..bd5f4c4b658 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -287,6 +287,7 @@ in nzbget = handleTest ./nzbget.nix {}; nzbhydra2 = handleTest ./nzbhydra2.nix {}; oh-my-zsh = handleTest ./oh-my-zsh.nix {}; + ombi = handleTest ./ombi.nix {}; openarena = handleTest ./openarena.nix {}; openldap = handleTest ./openldap.nix {}; opensmtpd = handleTest ./opensmtpd.nix {}; diff --git a/nixos/tests/ombi.nix b/nixos/tests/ombi.nix new file mode 100644 index 00000000000..bfca86af817 --- /dev/null +++ b/nixos/tests/ombi.nix @@ -0,0 +1,18 @@ +import ./make-test-python.nix ({ lib, ... }: + +with lib; + +{ + name = "ombi"; + meta.maintainers = with maintainers; [ woky ]; + + nodes.machine = + { pkgs, ... }: + { services.ombi.enable = true; }; + + testScript = '' + machine.wait_for_unit("ombi.service") + machine.wait_for_open_port("5000") + machine.succeed("curl --fail http://localhost:5000/") + ''; +})