From 619394f509ede4584d4f0f18db31e73b3ab492b7 Mon Sep 17 00:00:00 2001 From: bsodfather Date: Sun, 30 Aug 2026 01:28:48 +0300 Subject: [PATCH] test(admin): stabilize telemetry failure fixture --- apps/admin-api/tests/integration/common.rs | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/apps/admin-api/tests/integration/common.rs b/apps/admin-api/tests/integration/common.rs index b8f8dae..bf59278 100644 --- a/apps/admin-api/tests/integration/common.rs +++ b/apps/admin-api/tests/integration/common.rs @@ -114,10 +114,14 @@ pub(super) fn build_test_app_with_external_references( allowed_url_prefixes: Vec, ) -> Router { build_app(AppState { - service: test_service_with_external_references( + service: test_service_with_external_references_timeout( registry, storage_root, allowed_url_prefixes, + // This HTTP fixture asserts classification of an immediate + // upstream status. Leave headroom for CI scheduling jitter so the + // unrelated chain-timeout branch cannot win first. + 10_000, ), api_rate_limiter: crank_runtime::RequestRateLimiter::new( crank_runtime::RequestRateLimitConfig::new(10_000, 10_000).unwrap(), @@ -174,6 +178,20 @@ pub(super) fn test_service_with_external_references( registry: PostgresRegistry, storage_root: std::path::PathBuf, allowed_url_prefixes: Vec, +) -> AdminService { + test_service_with_external_references_timeout( + registry, + storage_root, + allowed_url_prefixes, + 2_000, + ) +} + +fn test_service_with_external_references_timeout( + registry: PostgresRegistry, + storage_root: std::path::PathBuf, + allowed_url_prefixes: Vec, + fetch_timeout_ms: u64, ) -> AdminService { let outbound_policy = crank_runtime::OutboundHttpPolicy::allowing_hosts(["127.0.0.1"]); let runtime = crank_runtime::community_with_outbound_policy(outbound_policy.clone()).build(); @@ -189,7 +207,7 @@ pub(super) fn test_service_with_external_references( max_depth: 8, max_documents: 32, max_fetch_bytes: 64 * 1024, - fetch_timeout_ms: 2_000, + fetch_timeout_ms, max_expanded_nodes: 10_000, }) .unwrap()