Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
dkhalanskyjb committed Oct 18, 2024
1 parent 8de9787 commit 090a01d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/jvm/test/ConvertersTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
package kotlinx.datetime.test

import kotlinx.datetime.*
import org.junit.experimental.theories.suppliers.TestedOn
import kotlin.random.Random
import kotlin.test.*
import java.time.Instant as JTInstant
Expand Down Expand Up @@ -38,7 +37,6 @@ class ConvertersTest {
}
}

@OptIn(ExperimentalStdlibApi::class)
private fun randomDate(): LocalDate {
val year = Random.nextInt(-20000, 20000)
val month = Month.entries.random()
Expand Down Expand Up @@ -197,6 +195,7 @@ class ConvertersTest {
fun test(month: Month) {
val jtMonth = month.toJavaMonth()
assertEquals(month, jtMonth.toKotlinMonth())
assertEquals(month.name, jtMonth.name)
}
Month.entries.forEach(::test)
assertEquals(Month.JANUARY, java.time.Month.JANUARY.toKotlinMonth())
Expand All @@ -207,6 +206,7 @@ class ConvertersTest {
fun test(dayOfWeek: DayOfWeek) {
val jtDayOfWeek = dayOfWeek.toJavaDayOfWeek()
assertEquals(dayOfWeek, jtDayOfWeek.toKotlinDayOfWeek())
assertEquals(dayOfWeek.name, jtDayOfWeek.name)
}
DayOfWeek.entries.forEach(::test)
assertEquals(DayOfWeek.MONDAY, java.time.DayOfWeek.MONDAY.toKotlinDayOfWeek())
Expand Down

0 comments on commit 090a01d

Please sign in to comment.