mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
test/coturn: add some sanity-checks
This commit is contained in:
parent
064b4d4ac1
commit
2b152c5727
@ -1,4 +1,4 @@
|
||||
import ./make-test-python.nix ({ ... }: {
|
||||
import ./make-test-python.nix ({ pkgs, ... }: {
|
||||
name = "coturn";
|
||||
nodes = {
|
||||
default = {
|
||||
@ -25,5 +25,9 @@ import ./make-test-python.nix ({ ... }: {
|
||||
with subtest("works with static-auth-secret-file"):
|
||||
secretsfile.wait_for_unit("coturn.service")
|
||||
secretsfile.succeed("grep 'some-very-secret-string' /run/coturn/turnserver.cfg")
|
||||
# Forbidden IP, fails:
|
||||
secretsfile.fail("${pkgs.coturn}/bin/turnutils_uclient -W some-very-secret-string 127.0.0.1 -DgX -e 127.0.0.1 -n 1 -c -y")
|
||||
# allowed-peer-ip, should succeed:
|
||||
secretsfile.succeed("${pkgs.coturn}/bin/turnutils_uclient -W some-very-secret-string 192.168.1.2 -DgX -e 192.168.1.2 -n 1 -c -y")
|
||||
'';
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user