From 4ae6c65bc589807c787be4b31809c15649a468f4 Mon Sep 17 00:00:00 2001 From: Bernardo Meurer Costa Date: Sat, 18 Oct 2025 23:48:54 +0000 Subject: [PATCH] test(tests/nixos/s3-binary-cache-store): verify credential caching in concurrent fetches Add assertion to test_concurrent_fetches to verify that only one credential provider is created even with 5 concurrent fetches. --- tests/nixos/s3-binary-cache-store.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/nixos/s3-binary-cache-store.nix b/tests/nixos/s3-binary-cache-store.nix index d47273196..9a0975eed 100644 --- a/tests/nixos/s3-binary-cache-store.nix +++ b/tests/nixos/s3-binary-cache-store.nix @@ -418,6 +418,13 @@ in f"Expected 5 FileTransfer instances for 5 concurrent fetches, got {transfers_created}" ) + if providers_created != 1: + print("Debug output:") + print(output) + raise Exception( + f"Expected 1 credential provider for concurrent fetches, got {providers_created}" + ) + @setup_s3() def test_compression_narinfo_gzip(bucket): """Test narinfo compression with gzip"""