mirror of
https://github.com/element-hq/element-android
synced 2024-11-27 11:59:12 +03:00
Renaming method to create static location event
This commit is contained in:
parent
879cafc8d1
commit
707507202d
4 changed files with 8 additions and 8 deletions
|
@ -38,7 +38,7 @@ internal class DefaultSendStaticLocationTask @Inject constructor(
|
|||
) : SendStaticLocationTask {
|
||||
|
||||
override suspend fun execute(params: SendStaticLocationTask.Params): Cancelable {
|
||||
val event = localEchoEventFactory.createLocationEvent(
|
||||
val event = localEchoEventFactory.createStaticLocationEvent(
|
||||
roomId = params.roomId,
|
||||
latitude = params.latitude,
|
||||
longitude = params.longitude,
|
||||
|
|
|
@ -244,7 +244,7 @@ internal class LocalEchoEventFactory @Inject constructor(
|
|||
)
|
||||
}
|
||||
|
||||
fun createLocationEvent(
|
||||
fun createStaticLocationEvent(
|
||||
roomId: String,
|
||||
latitude: Double,
|
||||
longitude: Double,
|
||||
|
|
|
@ -55,13 +55,13 @@ internal class DefaultSendStaticLocationTaskTest {
|
|||
isUserLocation = true
|
||||
)
|
||||
|
||||
val event = fakeLocalEchoEventFactory.givenCreateLocationEvent(
|
||||
val event = fakeLocalEchoEventFactory.givenCreateStaticLocationEvent(
|
||||
withLocalEcho = true
|
||||
)
|
||||
|
||||
defaultSendStaticLocationTask.execute(params)
|
||||
|
||||
fakeLocalEchoEventFactory.verifyCreateLocationEvent(
|
||||
fakeLocalEchoEventFactory.verifyCreateStaticLocationEvent(
|
||||
roomId = params.roomId,
|
||||
latitude = params.latitude,
|
||||
longitude = params.longitude,
|
||||
|
|
|
@ -28,10 +28,10 @@ internal class FakeLocalEchoEventFactory {
|
|||
|
||||
val instance = mockk<LocalEchoEventFactory>()
|
||||
|
||||
fun givenCreateLocationEvent(withLocalEcho: Boolean): Event {
|
||||
fun givenCreateStaticLocationEvent(withLocalEcho: Boolean): Event {
|
||||
val event = Event()
|
||||
every {
|
||||
instance.createLocationEvent(
|
||||
instance.createStaticLocationEvent(
|
||||
roomId = any(),
|
||||
latitude = any(),
|
||||
longitude = any(),
|
||||
|
@ -64,7 +64,7 @@ internal class FakeLocalEchoEventFactory {
|
|||
return event
|
||||
}
|
||||
|
||||
fun verifyCreateLocationEvent(
|
||||
fun verifyCreateStaticLocationEvent(
|
||||
roomId: String,
|
||||
latitude: Double,
|
||||
longitude: Double,
|
||||
|
@ -72,7 +72,7 @@ internal class FakeLocalEchoEventFactory {
|
|||
isUserLocation: Boolean
|
||||
) {
|
||||
verify {
|
||||
instance.createLocationEvent(
|
||||
instance.createStaticLocationEvent(
|
||||
roomId = roomId,
|
||||
latitude = latitude,
|
||||
longitude = longitude,
|
||||
|
|
Loading…
Reference in a new issue