Removes unused imports
This commit is contained in:
parent
eb46067c08
commit
82b5fc9557
|
@ -19,7 +19,6 @@ package org.matrix.android.sdk.internal.session.space
|
|||
import org.matrix.android.sdk.internal.network.GlobalErrorReceiver
|
||||
import org.matrix.android.sdk.internal.network.executeRequest
|
||||
import org.matrix.android.sdk.internal.task.Task
|
||||
import retrofit2.HttpException
|
||||
import javax.inject.Inject
|
||||
|
||||
internal interface ResolveSpaceInfoTask : Task<ResolveSpaceInfoTask.Params, SpacesResponse> {
|
||||
|
|
|
@ -18,13 +18,9 @@ package org.matrix.android.sdk.test.fakes
|
|||
|
||||
import io.mockk.coEvery
|
||||
import io.mockk.mockk
|
||||
import okhttp3.ResponseBody.Companion.toResponseBody
|
||||
import org.matrix.android.sdk.internal.session.space.SpaceApi
|
||||
import org.matrix.android.sdk.internal.session.space.SpacesResponse
|
||||
import org.matrix.android.sdk.test.fixtures.ResolveSpaceInfoTaskParamsFixture
|
||||
import org.matrix.android.sdk.test.fixtures.SpacesResponseFixture
|
||||
import retrofit2.HttpException
|
||||
import retrofit2.Response
|
||||
|
||||
internal class FakeSpaceApi {
|
||||
|
||||
|
@ -37,8 +33,7 @@ internal class FakeSpaceApi {
|
|||
}
|
||||
|
||||
fun givenStableEndpointFails() {
|
||||
val errorResponse = Response.error<SpacesResponse>(500, "".toResponseBody())
|
||||
coEvery { instance.getSpaceHierarchy(params.spaceId, params.suggestedOnly, params.limit, params.maxDepth, params.from) } throws HttpException(errorResponse)
|
||||
coEvery { instance.getSpaceHierarchy(params.spaceId, params.suggestedOnly, params.limit, params.maxDepth, params.from) } throws Exception()
|
||||
}
|
||||
|
||||
fun givenUnstableEndpointWorks() {
|
||||
|
|
Loading…
Reference in New Issue