diff --git a/quic/s2n-quic/src/tests/skip_packets.rs b/quic/s2n-quic/src/tests/skip_packets.rs index b4b9952922..c528bc5c05 100644 --- a/quic/s2n-quic/src/tests/skip_packets.rs +++ b/quic/s2n-quic/src/tests/skip_packets.rs @@ -88,8 +88,11 @@ fn optimistic_ack_mitigation() { // Verify that both client and server are skipping packets for Optimistic // Ack attack mitigation. - assert_eq!(server_skip_count, 5); - assert_eq!(client_skip_count, 5); + // + // The exact number of skipped packets depends on randomness, so this test may be changed by + // unrelated changes. The important thing is that both numbers are non-zero. + assert_eq!(server_skip_count, 4); + assert_eq!(client_skip_count, 4); } // Mimic an Optimistic Ack attack and confirm the connection is closed with