mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-06-05 21:03:40 +00:00
nixos/tests/rqbit: convert to runTest
This commit is contained in:
committed by
Adam C. Stephens
parent
d8ea04992a
commit
6b22df9c5c
@@ -1389,7 +1389,7 @@ in
|
||||
rosenpass = runTest ./rosenpass.nix;
|
||||
roundcube = runTest ./roundcube.nix;
|
||||
routinator = handleTest ./routinator.nix { };
|
||||
rqbit = handleTest ./rqbit.nix { };
|
||||
rqbit = runTest ./rqbit.nix;
|
||||
rshim = handleTest ./rshim.nix { };
|
||||
rspamd = handleTest ./rspamd.nix { };
|
||||
rspamd-trainer = runTest ./rspamd-trainer.nix;
|
||||
|
||||
@@ -1,30 +1,28 @@
|
||||
import ./make-test-python.nix (
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
port = 3030;
|
||||
in
|
||||
{
|
||||
name = "rqbit";
|
||||
meta = {
|
||||
maintainers = with pkgs.lib.maintainers; [ CodedNil ];
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
port = 3030;
|
||||
in
|
||||
{
|
||||
name = "rqbit";
|
||||
meta = {
|
||||
maintainers = with pkgs.lib.maintainers; [ CodedNil ];
|
||||
};
|
||||
|
||||
nodes.machine =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
services.rqbit = {
|
||||
httpPort = port;
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
};
|
||||
|
||||
nodes.machine =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
services.rqbit = {
|
||||
httpPort = port;
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
};
|
||||
testScript = /* python */ ''
|
||||
machine.start()
|
||||
machine.wait_for_unit("rqbit.service")
|
||||
machine.wait_for_open_port(${toString port})
|
||||
|
||||
testScript = /* python */ ''
|
||||
machine.start()
|
||||
machine.wait_for_unit("rqbit.service")
|
||||
machine.wait_for_open_port(${toString port})
|
||||
|
||||
machine.succeed("curl --fail http://localhost:${toString port}")
|
||||
'';
|
||||
}
|
||||
)
|
||||
machine.succeed("curl --fail http://localhost:${toString port}")
|
||||
'';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user