Skip to content

Commit cad6361

Browse files
committed
Fix unit tests
1 parent 8802b92 commit cad6361

File tree

2 files changed

+3
-36
lines changed
  • app/src/test/kotlin/io/homeassistant/companion/android/widgets/todo
  • common/src/androidTest/kotlin/io/homeassistant/companion/android

2 files changed

+3
-36
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
package io.homeassistant.companion.android.widgets.todo
22

33
import io.homeassistant.companion.android.common.data.integration.Entity
4-
import java.util.Calendar
4+
import java.time.LocalDateTime
55

66
internal fun fakeServerEntity(entityId: String, friendlyName: String? = null): Entity {
77
return Entity(
88
entityId = entityId,
99
state = "",
1010
attributes = if (friendlyName != null) mapOf("friendly_name" to friendlyName) else emptyMap(),
11-
lastChanged = Calendar.getInstance(),
12-
lastUpdated = Calendar.getInstance(),
11+
lastChanged = LocalDateTime.now(),
12+
lastUpdated = LocalDateTime.now(),
1313
)
1414
}

common/src/androidTest/kotlin/io/homeassistant/companion/android/JacksonDummyTest.kt

Lines changed: 0 additions & 33 deletions
This file was deleted.

0 commit comments

Comments
 (0)