2021-08-07 05:02:28 +00:00
|
|
|
import ./make-test-python.nix ({ pkgs, ... }: {
|
|
|
|
name = "isso";
|
|
|
|
meta = with pkgs.lib.maintainers; {
|
2023-02-14 14:54:45 +00:00
|
|
|
maintainers = [ ];
|
2021-08-07 05:02:28 +00:00
|
|
|
};
|
|
|
|
|
2022-03-20 23:15:30 +00:00
|
|
|
nodes.machine = { config, pkgs, ... }: {
|
2021-08-07 06:32:06 +00:00
|
|
|
services.isso = {
|
|
|
|
enable = true;
|
|
|
|
settings = {
|
|
|
|
general = {
|
|
|
|
dbpath = "/var/lib/isso/comments.db";
|
|
|
|
host = "http://localhost";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
2021-08-07 05:02:28 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
testScript = let
|
|
|
|
port = 8080;
|
|
|
|
in
|
|
|
|
''
|
2021-08-07 06:32:06 +00:00
|
|
|
machine.wait_for_unit("isso.service")
|
2021-08-07 05:02:28 +00:00
|
|
|
|
2022-08-04 20:58:38 +00:00
|
|
|
machine.wait_for_open_port(${toString port})
|
2021-08-07 05:02:28 +00:00
|
|
|
|
|
|
|
machine.succeed("curl --fail http://localhost:${toString port}/?uri")
|
|
|
|
machine.succeed("curl --fail http://localhost:${toString port}/js/embed.min.js")
|
|
|
|
'';
|
|
|
|
})
|