1import ./make-test-python.nix (
2 { pkgs, lib, ... }:
3 let
4 port = 8082;
5 in
6 {
7 name = "languagetool";
8 meta = with lib.maintainers; {
9 maintainers = [ fbeffa ];
10 };
11
12 nodes.machine =
13 { ... }:
14 {
15 services.languagetool.enable = true;
16 services.languagetool.port = port;
17 };
18
19 testScript = ''
20 machine.start()
21 machine.wait_for_unit("languagetool.service")
22 machine.wait_for_open_port(${toString port})
23 machine.wait_until_succeeds('curl -d "language=en-US" -d "text=a simple test" http://localhost:${toString port}/v2/check')
24 '';
25 }
26)