use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by signalapp.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method add_from_invite_link_access_control_passed_though_5_administrator.
@Test
public void add_from_invite_link_access_control_passed_though_5_administrator() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setAddFromInviteLink(AccessControl.AccessRequired.ADMINISTRATOR).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertEquals(AccessControl.AccessRequired.ADMINISTRATOR, decryptedGroupJoinInfo.getAddFromInviteLink());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by signalapp.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method pending_approval_passed_though_7_false.
@Test
public void pending_approval_passed_though_7_false() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setPendingAdminApproval(false).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertFalse(decryptedGroupJoinInfo.getPendingAdminApproval());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by signalapp.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method decrypt_title_field_2.
@Test
public void decrypt_title_field_2() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setTitle(groupOperations.encryptTitle("Title!")).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertEquals("Title!", decryptedGroupJoinInfo.getTitle());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by signalapp.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method avatar_field_passed_through_3.
@Test
public void avatar_field_passed_through_3() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setAvatar("AvatarCdnKey").build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertEquals("AvatarCdnKey", decryptedGroupJoinInfo.getAvatar());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by signalapp.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method pending_approval_passed_though_7_true.
@Test
public void pending_approval_passed_though_7_true() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setPendingAdminApproval(true).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertTrue(decryptedGroupJoinInfo.getPendingAdminApproval());
}
Aggregations