use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by WhisperSystems.
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());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by WhisperSystems.
the class GroupsV2Operations_decrypt_groupJoinInfo_Test method add_from_invite_link_access_control_passed_though_5_any.
@Test
public void add_from_invite_link_access_control_passed_though_5_any() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setAddFromInviteLink(AccessControl.AccessRequired.ANY).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertEquals(AccessControl.AccessRequired.ANY, decryptedGroupJoinInfo.getAddFromInviteLink());
}
use of org.signal.storageservice.protos.groups.GroupJoinInfo in project Signal-Android by WhisperSystems.
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 WhisperSystems.
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 member_count_passed_through_4.
@Test
public void member_count_passed_through_4() {
GroupJoinInfo groupJoinInfo = GroupJoinInfo.newBuilder().setMemberCount(97).build();
DecryptedGroupJoinInfo decryptedGroupJoinInfo = groupOperations.decryptGroupJoinInfo(groupJoinInfo);
assertEquals(97, decryptedGroupJoinInfo.getMemberCount());
}
Aggregations