Skip to content

Commit

Permalink
Added integration test for org members list action
Browse files Browse the repository at this point in the history
  • Loading branch information
a2xchip committed Jan 22, 2025
1 parent a389319 commit 787ab6f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/integrationTest/kotlin/OrganizationsIntegrationTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package com.jeliuc.turso.sdk

import com.jeliuc.turso.sdk.model.ListAuditLogsResponse
import com.jeliuc.turso.sdk.model.ListInvitesResponse
import com.jeliuc.turso.sdk.model.ListMembersResponse
import com.jeliuc.turso.sdk.resource.organizations
import io.ktor.client.engine.cio.CIO
import kotlinx.coroutines.runBlocking
Expand Down Expand Up @@ -39,5 +40,15 @@ class OrganizationsIntegrationTest {
assertIs<ListAuditLogsResponse>(logs)
}

@Test
fun `can list members`() {
val members =
runBlocking {
getClient().organizations.members.list(organization)
}

assertIs<ListMembersResponse>(members)
}

private fun getClient(): TursoClient = TursoClient.using(CIO.create(), token)
}

0 comments on commit 787ab6f

Please sign in to comment.