about summary refs log tree commit diff
path: root/nixos/tests/quickwit.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/tests/quickwit.nix')
-rw-r--r--nixos/tests/quickwit.nix31
1 files changed, 31 insertions, 0 deletions
diff --git a/nixos/tests/quickwit.nix b/nixos/tests/quickwit.nix
new file mode 100644
index 0000000000000..145959f7d3f51
--- /dev/null
+++ b/nixos/tests/quickwit.nix
@@ -0,0 +1,31 @@
+import ./make-test-python.nix ({ lib, pkgs, ... }:
+
+{
+  name = "quickwit";
+  meta.maintainers = [ pkgs.lib.maintainers.happysalada ];
+
+  nodes = {
+    quickwit = { config, pkgs, ... }: {
+      services.quickwit.enable = true;
+    };
+  };
+
+  testScript =
+  ''
+    quickwit.wait_for_unit("quickwit")
+    quickwit.wait_for_open_port(7280)
+    quickwit.wait_for_open_port(7281)
+
+    quickwit.wait_until_succeeds(
+      "journalctl -o cat -u quickwit.service | grep 'version: ${pkgs.quickwit.version}'"
+    )
+
+    quickwit.wait_until_succeeds(
+      "journalctl -o cat -u quickwit.service | grep 'transitioned to ready state'"
+    )
+
+    quickwit.log(quickwit.succeed(
+      "systemd-analyze security quickwit.service | grep -v '✓'"
+    ))
+  '';
+})