package de.trainingstagebuch.app.utils

import org.junit.Assert.assertEquals
import org.junit.Test

class BackoffUtilsTest {

    @Test
    fun `exponentialDelayMs doubles and caps at max`() {
        assertEquals(1_000L, BackoffUtils.exponentialDelayMs(1))
        assertEquals(2_000L, BackoffUtils.exponentialDelayMs(2))
        assertEquals(30_000L, BackoffUtils.exponentialDelayMs(10))
    }
}
