diff options
author | Pol Dellaiera <pol.dellaiera@protonmail.com> | 2023-05-15 15:33:37 +0200 |
---|---|---|
committer | Pol Dellaiera <pol.dellaiera@protonmail.com> | 2023-05-15 21:48:08 +0200 |
commit | cce7cdd2938c02a550270ef0e8185b4da9f66860 (patch) | |
tree | 5502b75451a8464c57ec691cebdc9745378e35f9 /nixos/tests | |
parent | 1d37fe1526f18f315eec9cd1a9f75846a1acddce (diff) |
nixosTests.openvscode-server: init
Diffstat (limited to 'nixos/tests')
-rw-r--r-- | nixos/tests/all-tests.nix | 1 | ||||
-rw-r--r-- | nixos/tests/openvscode-server.nix | 22 |
2 files changed, 23 insertions, 0 deletions
diff --git a/nixos/tests/all-tests.nix b/nixos/tests/all-tests.nix index 008dfbe393772..7580c2fbace76 100644 --- a/nixos/tests/all-tests.nix +++ b/nixos/tests/all-tests.nix @@ -554,6 +554,7 @@ in { opentabletdriver = handleTest ./opentabletdriver.nix {}; owncast = handleTest ./owncast.nix {}; image-contents = handleTest ./image-contents.nix {}; + openvscode-server = handleTest ./openvscode-server.nix {}; orangefs = handleTest ./orangefs.nix {}; os-prober = handleTestOn ["x86_64-linux"] ./os-prober.nix {}; osrm-backend = handleTest ./osrm-backend.nix {}; diff --git a/nixos/tests/openvscode-server.nix b/nixos/tests/openvscode-server.nix new file mode 100644 index 0000000000000..cbff8e09c5938 --- /dev/null +++ b/nixos/tests/openvscode-server.nix @@ -0,0 +1,22 @@ +import ./make-test-python.nix ({pkgs, lib, ...}: +{ + name = "openvscode-server"; + + nodes = { + machine = {pkgs, ...}: { + services.openvscode-server = { + enable = true; + withoutConnectionToken = true; + }; + }; + }; + + testScript = '' + start_all() + machine.wait_for_unit("openvscode-server.service") + machine.wait_for_open_port(3000) + machine.succeed("curl -k --fail http://localhost:3000", timeout=10) + ''; + + meta.maintainers = [ lib.maintainers.drupol ]; +}) |