Skip to content

Commit 1628a21

Browse files
committed
test: fix expected error when try to delegate other chat room's member
1 parent 93d8b4a commit 1628a21

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pennyway-domain/domain-service/src/test/java/kr/co/pennyway/domain/context/chat/collection/ChatRoomAdminDelegateOperationTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,8 @@ void shouldNotDelegateAdminToMemberInOtherChatRoom() {
8080

8181
// when & then
8282
assertThatThrownBy(operation::execute)
83-
.isInstanceOf(IllegalArgumentException.class);
83+
.isInstanceOf(ChatMemberErrorException.class)
84+
.hasFieldOrPropertyWithValue("chatMemberErrorCode", ChatMemberErrorCode.NOT_SAME_CHAT_ROOM);
8485
}
8586

8687
private ChatMember createChatMember(Long userId, Long chatMemberId, ChatMemberRole role, ChatRoom chatRoom) {

0 commit comments

Comments
 (0)