depot/third_party/nixpkgs/nixos/tests/tinyproxy.nix
Default email b5f92a349c Project import generated by Copybara.
GitOrigin-RevId: 7c9cc5a6e5d38010801741ac830a3f8fd667a7a0
2023-10-19 15:55:26 +02:00

20 lines
438 B
Nix

import ./make-test-python.nix ({ pkgs, ... }: {
name = "tinyproxy";
nodes.machine = { config, pkgs, ... }: {
services.tinyproxy = {
enable = true;
settings = {
Listen = "127.0.0.1";
Port = 8080;
};
};
};
testScript = ''
machine.wait_for_unit("tinyproxy.service")
machine.wait_for_open_port(8080)
machine.succeed('curl -s http://localhost:8080 |grep -i tinyproxy')
'';
})