diff --git a/example/ios/Podfile.lock b/example/ios/Podfile.lock index 1e9fe0656..c84964bb5 100644 --- a/example/ios/Podfile.lock +++ b/example/ios/Podfile.lock @@ -769,4 +769,4 @@ SPEC CHECKSUMS: PODFILE CHECKSUM: 95d6ace79946933ecf80684613842ee553dd76a2 -COCOAPODS: 1.14.2 +COCOAPODS: 1.15.2 diff --git a/example/src/tests/groupTests.ts b/example/src/tests/groupTests.ts index 34277e9c9..548a13c37 100644 --- a/example/src/tests/groupTests.ts +++ b/example/src/tests/groupTests.ts @@ -246,16 +246,30 @@ test('can get members of a group', async () => { const members = await group.members() assert(members.length === 2, `Should be 2 members but was ${members.length}`) - assert( - members[0].addresses[0].toLocaleLowerCase === - boClient.address.toLocaleLowerCase, - `Should be ${boClient.address} but was ${members[0].addresses[0]}` - ) - assert( - members[0].permissionLevel === "admin", - `Should be admin but was ${members[0].permissionLevel}` - ) + // We can not be sure of the order that members will be returned in + for (const member of members) { + // Alix created the group so they are a super admin + if ( + member.addresses[0].toLocaleLowerCase() === + alixClient.address.toLocaleLowerCase() + ) { + assert( + member.permissionLevel === 'super_admin', + `Should be super_admin but was ${member.permissionLevel}` + ) + } + // Bo did not create the group so he defaults to permission level "member" + if ( + member.addresses[0].toLocaleLowerCase() === + boClient.address.toLocaleLowerCase() + ) { + assert( + member.permissionLevel === 'member', + `Should be member but was ${member.permissionLevel}` + ) + } + } return true }) diff --git a/src/index.ts b/src/index.ts index 765ccd0e1..b0b6d10d2 100644 --- a/src/index.ts +++ b/src/index.ts @@ -862,7 +862,6 @@ export async function isInboxDenied( return XMTPModule.isInboxDenied(clientAddress, inboxId) } - export async function processGroupMessage< ContentTypes extends DefaultContentTypes = DefaultContentTypes, >(