tsshd: fix tests on Darwin (#481262)

This commit is contained in:
Sizhe Zhao
2026-02-08 06:35:17 +00:00
committed by GitHub
+18
View File
@@ -2,6 +2,7 @@
lib,
buildGoModule,
fetchFromGitHub,
stdenv,
versionCheckHook,
nix-update-script,
}:
@@ -24,6 +25,23 @@ buildGoModule (finalAttrs: {
"-w"
];
# Enable for upstream KCP and QUIC tests which require UDP binding on localhost
__darwinAllowLocalNetworking = true;
checkFlags =
let
skippedTests = [
# `quic.DialAddr` of `quic-go` invokes UDP writing with `sendmsg` from address `[::]`,
# causing these tests to fail even with the `__darwinAllowLocalNetworking` flag enabled.
"TestQUIC_InitialPacketSize"
"TestQUIC_RespectMTU"
"TestQUIC_CertValidation"
];
in
lib.optionals stdenv.hostPlatform.isDarwin [
"-skip=^${builtins.concatStringsSep "$|^" skippedTests}$"
];
doInstallCheck = true;
nativeCheckInputs = [
versionCheckHook