Skip to content

Commit 3f9b448

Browse files
committed
nix: raise the integration check timeout for slow nested-docker tests
The VM's nested docker runs multi-network route-convergence tests several-fold slower than bare metal, and -test.timeout=20m was too tight for the slowest (TestAutoApproveMultiNetwork timed out mid-run). Raise it to 45m with a matching globalTimeout so a slow test hits its own clean Go timeout, not the driver's.
1 parent 08263df commit 3f9b448

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

nix/tests/integration.nix

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,10 @@ in
5252
{
5353
name = "integration-${name}${lib.optionalString postgres "-pg"}";
5454

55+
# Cap the whole VM run above the per-test timeout below (45m) plus image-load
56+
# and boot, so a slow test hits its own clean Go timeout, not the driver's.
57+
globalTimeout = 4200;
58+
5559
nodes.machine = { ... }: {
5660
virtualisation.docker.enable = true;
5761

@@ -136,8 +140,12 @@ in
136140
"-e CI=1 "
137141
"-e SSL_CERT_FILE=${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt "
138142
"headscale:nix "
139-
"${testBin}/bin/integration.test -test.run '^${name}$' -test.v -test.timeout=20m",
140-
timeout=1800,
143+
# Heavy tests (multi-network route convergence) run several-fold slower
144+
# in the VM's nested docker than against bare metal; 20m was too tight
145+
# for the slowest (TestAutoApproveMultiNetwork). Give generous headroom,
146+
# within the globalTimeout set above.
147+
"${testBin}/bin/integration.test -test.run '^${name}$' -test.v -test.timeout=45m",
148+
timeout=2820,
141149
)
142150
print(out)
143151

0 commit comments

Comments
 (0)