@Test
    void testRegulateFailureDoesNotRecordSuccess() {
        when(successMonitor.getRateAndReset()).thenReturn((double) mbpsToBps(100.0));
        when(failureMonitor.getRateAndReset()).thenReturn((double) mbpsToBps(10.0));
        regulator.regulate();
        EvictingQueue<Double> queue = getSuccessRateQueue();
        assertTrue(queue.isEmpty(), "Queue should be empty as failure occurred");
    }
Converts a rate given in KB/s to bytes/s.
s3stream/src/test/java/com/automq/stream/s3/operator/TrafficRegulatorTest.java