Migrate junit.framework.Assert.assertEquals to kotlin.test.assertEquals

pull/1769/head
Quentin Hibon 2 years ago
parent 6b793c7c16
commit 5e490d88ee

@ -18,7 +18,6 @@
*/
package org.isoron.uhabits.core.commands
import junit.framework.Assert.assertEquals
import org.isoron.uhabits.core.BaseUnitTest
import org.isoron.uhabits.core.models.Entry
import org.isoron.uhabits.core.models.Habit
@ -26,6 +25,7 @@ import org.isoron.uhabits.core.models.Timestamp
import org.isoron.uhabits.core.utils.DateUtils.Companion.getToday
import org.junit.Before
import org.junit.Test
import kotlin.test.assertEquals
class CreateRepetitionCommandTest : BaseUnitTest() {
private lateinit var command: CreateRepetitionCommand

@ -18,7 +18,6 @@
*/
package org.isoron.uhabits.core.models
import junit.framework.Assert.assertEquals
import junit.framework.Assert.assertFalse
import junit.framework.Assert.assertNull
import org.hamcrest.CoreMatchers.equalTo
@ -31,6 +30,7 @@ import org.junit.rules.ExpectedException
import java.io.IOException
import java.io.StringWriter
import java.util.ArrayList
import kotlin.test.assertEquals
class HabitListTest : BaseUnitTest() {
@get:Rule

@ -19,7 +19,6 @@
package org.isoron.uhabits.core.models.sqlite
import junit.framework.Assert.assertEquals
import junit.framework.Assert.assertNull
import org.isoron.uhabits.core.BaseUnitTest.Companion.buildMemoryDatabase
import org.isoron.uhabits.core.database.Repository
@ -30,6 +29,7 @@ import org.isoron.uhabits.core.models.sqlite.records.EntryRecord
import org.isoron.uhabits.core.utils.DateUtils
import org.junit.Before
import org.junit.Test
import kotlin.test.assertEquals
class SQLiteEntryListTest {

@ -18,7 +18,6 @@
*/
package org.isoron.uhabits.core.preferences
import junit.framework.Assert.assertEquals
import junit.framework.Assert.assertFalse
import junit.framework.Assert.assertTrue
import org.hamcrest.CoreMatchers.equalTo
@ -28,6 +27,7 @@ import org.junit.Before
import org.junit.Test
import java.io.File
import java.util.Arrays
import kotlin.test.assertEquals
class PropertiesStorageTest : BaseUnitTest() {
private lateinit var storage: PropertiesStorage

@ -18,7 +18,6 @@
*/
package org.isoron.uhabits.core.utils
import junit.framework.Assert.assertEquals
import org.hamcrest.MatcherAssert.assertThat
import org.hamcrest.core.IsEqual.equalTo
import org.isoron.uhabits.core.BaseUnitTest
@ -40,6 +39,7 @@ import java.util.Calendar
import java.util.GregorianCalendar
import java.util.Locale
import java.util.TimeZone
import kotlin.test.assertEquals
class DateUtilsTest : BaseUnitTest() {
var firstWeekday = Calendar.SUNDAY

Loading…
Cancel
Save