Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hotfix/BE] 로그아웃 시 팔로워 수가 초기화 되는 현상을 수정한다 #676

Merged
merged 2 commits into from
Sep 26, 2022

Conversation

hamcheeseburger
Copy link
Collaborator

작업 내용

  • follow, unfollow 로직 MemberUpdate와 분리
  • 재로그인 시 팔로워 수가 변하지 않는지에 대한 인수테스트 추가

* fix: follow, unfollow 로직 MemberUpdate와 분리

* test: 재로그인 시 팔로워 수가 변하지 않는지에 대한 인수테스트 추가
@github-actions
Copy link

🚧 Analysis Results

F12-676

Bugs : 0 ✅
Vulnerabilities : 0 ✅
Security Hotspots : 3 ❌
Code Smells : 100 ✅
Duplicated Lines Density : 0.0 ✅
Test Coverage : 92.8 ✅
Tests : 289
Test Success Density : 100.0
Test Failures : 0

분석 결과 확인하기

Copy link
Collaborator

@yangdongjue5510 yangdongjue5510 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨어요!!!

Copy link
Collaborator

@yh20studio yh20studio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

아주 완벽하게 하셨네요 굳굳 👍

Copy link
Collaborator

@Youngyoon-1 Youngyoon-1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

깔끔하게 해결해주셨군요! 고생하셨습니다!

LoginResponse followingResponse = 민초.로그인을_한다();
민초.로그인한_상태로(followingResponse.getToken()).추가정보를_입력한다(memberRequest);

final LoginResponse followerResponse = 코린.로그인을_한다();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

final 키워드가 붙어있군용

Copy link
Collaborator

@Ohzzi Ohzzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

메서드 이름 바꿔주세요

Comment on lines 100 to 105
public void follow() {
this.followerCount += 1;
}

public void unfollow() {
if (this.followerCount == 0) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이 member가 follow나 unfollow 동작을 하는 것이 아닌데 follow와 unfollow의 능동형으로 쓰는 것은 어색한 것 같아요!
followerCount에 초점을 두고 increaseFollowerCount, decreaseFollowerCount로 쓰는 것이 어떨까요?

@@ -640,6 +636,27 @@ class MemberAcceptanceTest extends AcceptanceTest {
);
}

@Test
void 재로그인_시_팔로워_수가_변하지_않는다() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@github-actions
Copy link

🚧 Analysis Results

F12-676

Bugs : 0 ✅
Vulnerabilities : 0 ✅
Security Hotspots : 3 ❌
Code Smells : 100 ✅
Duplicated Lines Density : 0.0 ✅
Test Coverage : 92.8 ✅
Tests : 293
Test Success Density : 100.0
Test Failures : 0

분석 결과 확인하기

@Ohzzi Ohzzi merged commit 9fba98e into main Sep 26, 2022
@Ohzzi Ohzzi deleted the hotfix/be/follower_count branch October 5, 2022 00:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants