diff options
author | ocfox <i@ocfox.me> | 2024-01-25 12:23:53 +0800 |
---|---|---|
committer | ocfox <i@ocfox.me> | 2024-01-29 00:44:36 +0800 |
commit | 2e4d7b7ad23ce9e95d828fe02d9ef5be3dd9e7be (patch) | |
tree | 50279e6dea189b7b39b2011afe05a0dd16f83602 /nixos/tests/transfer-sh.nix | |
parent | 01e674ba9038a1943d6227468501eef08735ead2 (diff) |
nixosTests.transfer-sh: init
Diffstat (limited to 'nixos/tests/transfer-sh.nix')
-rw-r--r-- | nixos/tests/transfer-sh.nix | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/nixos/tests/transfer-sh.nix b/nixos/tests/transfer-sh.nix new file mode 100644 index 0000000000000..f4ab7d28858e1 --- /dev/null +++ b/nixos/tests/transfer-sh.nix @@ -0,0 +1,20 @@ +import ./make-test-python.nix ({ pkgs, lib, ... }: { + name = "transfer-sh"; + + meta = { + maintainers = with lib.maintainers; [ ocfox ]; + }; + + nodes.machine = { pkgs, ... }: { + services.transfer-sh = { + enable = true; + settings.LISTENER = ":1234"; + }; + }; + + testScript = '' + machine.wait_for_unit("transfer-sh.service") + machine.wait_for_open_port(1234) + machine.succeed("curl --fail http://localhost:1234/") + ''; +}) |