tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
nixos/tests/podgrab: init
Bruno BELANYI
4 years ago
1144486f
f1b36d19
+38
-1
3 changed files
expand all
collapse all
unified
split
nixos
tests
all-tests.nix
podgrab.nix
pkgs
servers
misc
podgrab
default.nix
+1
nixos/tests/all-tests.nix
···
321
321
pleroma = handleTestOn [ "x86_64-linux" "aarch64-linux" ] ./pleroma.nix {};
322
322
plikd = handleTest ./plikd.nix {};
323
323
plotinus = handleTest ./plotinus.nix {};
324
324
+
podgrab = handleTest ./podgrab.nix {};
324
325
podman = handleTestOn ["x86_64-linux"] ./podman.nix {};
325
326
pomerium = handleTestOn ["x86_64-linux"] ./pomerium.nix {};
326
327
postfix = handleTest ./postfix.nix {};
+34
nixos/tests/podgrab.nix
···
1
1
+
let
2
2
+
defaultPort = 8080;
3
3
+
customPort = 4242;
4
4
+
in
5
5
+
import ./make-test-python.nix ({ pkgs, ... }: {
6
6
+
name = "podgrab";
7
7
+
8
8
+
nodes = {
9
9
+
default = { ... }: {
10
10
+
services.podgrab.enable = true;
11
11
+
};
12
12
+
13
13
+
customized = { ... }: {
14
14
+
services.podgrab = {
15
15
+
enable = true;
16
16
+
port = customPort;
17
17
+
};
18
18
+
};
19
19
+
};
20
20
+
21
21
+
testScript = ''
22
22
+
start_all()
23
23
+
24
24
+
default.wait_for_unit("podgrab")
25
25
+
default.wait_for_open_port("${toString defaultPort}")
26
26
+
default.succeed("curl --fail http://localhost:${toString defaultPort}")
27
27
+
28
28
+
customized.wait_for_unit("podgrab")
29
29
+
customized.wait_for_open_port("${toString customPort}")
30
30
+
customized.succeed("curl --fail http://localhost:${toString customPort}")
31
31
+
'';
32
32
+
33
33
+
meta.maintainers = with pkgs.lib.maintainers; [ ambroisie ];
34
34
+
})
+3
-1
pkgs/servers/misc/podgrab/default.nix
···
1
1
-
{ lib, fetchFromGitHub, buildGoModule }:
1
1
+
{ lib, fetchFromGitHub, buildGoModule, nixosTests }:
2
2
3
3
buildGoModule rec {
4
4
pname = "podgrab";
···
18
18
cp -r $src/client $out/share/
19
19
cp -r $src/webassets $out/share/
20
20
'';
21
21
+
22
22
+
passthru.tests = { inherit (nixosTests) podgrab; };
21
23
22
24
meta = with lib; {
23
25
description = "A self-hosted podcast manager to download episodes as soon as they become live";