1 import ./make-test-python.nix ({ pkgs, lib, ... }: {
3 meta.maintainers = with lib.maintainers; [ tomasajt ];
6 machine1 = { pkgs, ... }: {
7 services.lanraragi.enable = true;
9 machine2 = { pkgs, ... }: {
10 services.lanraragi = {
12 passwordFile = pkgs.writeText "lrr-test-pass" ''
13 Ultra-secure-p@ssword-"with-spec1al\chars
18 passwordFile = pkgs.writeText "redis-lrr-test-pass" ''
29 machine1.wait_for_unit("lanraragi.service")
30 machine1.wait_until_succeeds("curl -f localhost:3000")
31 machine1.succeed("[ $(curl -o /dev/null -X post 'http://localhost:3000/login' --data-raw 'password=kamimamita' -w '%{http_code}') -eq 302 ]")
33 machine2.wait_for_unit("lanraragi.service")
34 machine2.wait_until_succeeds("curl -f localhost:4000")
35 machine2.succeed("[ $(curl -o /dev/null -X post 'http://localhost:4000/login' --data-raw 'password=Ultra-secure-p@ssword-\"with-spec1al\\chars' -w '%{http_code}') -eq 302 ]")