diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/common/relay.rs | 2 | ||||
| -rw-r--r-- | tests/sync/maintainer_reprocessing.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/common/relay.rs b/tests/common/relay.rs index 0ec9a2e..b1e96cf 100644 --- a/tests/common/relay.rs +++ b/tests/common/relay.rs | |||
| @@ -204,7 +204,7 @@ impl TestRelay { | |||
| 204 | .env("NGIT_GIT_DATA_PATH", git_data_dir.path()) | 204 | .env("NGIT_GIT_DATA_PATH", git_data_dir.path()) |
| 205 | .env("NGIT_DATABASE_BACKEND", "memory") // Force in-memory database for isolation | 205 | .env("NGIT_DATABASE_BACKEND", "memory") // Force in-memory database for isolation |
| 206 | .env("NGIT_OWNER_NPUB", &test_npub) | 206 | .env("NGIT_OWNER_NPUB", &test_npub) |
| 207 | .env("NGIT_SYNC_BATCH_WINDOW_MS", "200") // Fast batch window for tests (200ms instead of 5s default) | 207 | .env("NGIT_TEST", "1") // Enable test mode: fast timers (200ms batch window, 200ms purgatory sync) |
| 208 | .env("NGIT_SYNC_STARTUP_DELAY_SECS", "0") // No startup delay for faster tests | 208 | .env("NGIT_SYNC_STARTUP_DELAY_SECS", "0") // No startup delay for faster tests |
| 209 | .env("NGIT_SYNC_STARTUP_JITTER_MS", "0") // No jitter for tests | 209 | .env("NGIT_SYNC_STARTUP_JITTER_MS", "0") // No jitter for tests |
| 210 | .env("NGIT_SYNC_DISCONNECT_CHECK_INTERVAL_SECS", "1") // Fast reconnect attempts for tests | 210 | .env("NGIT_SYNC_DISCONNECT_CHECK_INTERVAL_SECS", "1") // Fast reconnect attempts for tests |
diff --git a/tests/sync/maintainer_reprocessing.rs b/tests/sync/maintainer_reprocessing.rs index 61d8e14..ff1eb43 100644 --- a/tests/sync/maintainer_reprocessing.rs +++ b/tests/sync/maintainer_reprocessing.rs | |||
| @@ -377,7 +377,7 @@ async fn test_multiple_maintainers_all_reprocessed() { | |||
| 377 | println!("relay_b started at {}", relay_b.url()); | 377 | println!("relay_b started at {}", relay_b.url()); |
| 378 | 378 | ||
| 379 | // Give relay_b's SyncManager time to complete the initial negentropy sync with relay_a. | 379 | // Give relay_b's SyncManager time to complete the initial negentropy sync with relay_a. |
| 380 | // The negentropy sync completes within ~200ms (NGIT_SYNC_BATCH_WINDOW_MS=200), but we | 380 | // The negentropy sync completes within ~200ms (NGIT_TEST=1 sets batch window to 200ms), but we |
| 381 | // allow extra time for slow CI environments. | 381 | // allow extra time for slow CI environments. |
| 382 | tokio::time::sleep(Duration::from_secs(3)).await; | 382 | tokio::time::sleep(Duration::from_secs(3)).await; |
| 383 | println!("✓ relay_b synced from relay_a (maintainer announcements should be in hot cache)"); | 383 | println!("✓ relay_b synced from relay_a (maintainer announcements should be in hot cache)"); |