Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
체크 리스트
test를 실행했을 때, 모든 테스트가 정상적으로 통과했나요?어떤 부분에 집중하여 리뷰해야 할까요?
책임의 기준 정하기
'승패는 플레이어가 판단하는가?', '참가자들은 자신의 역할을 알고있어야 하는가? (dealer, player)' 등 해당 도메인의 책임 범위? 기준?을 잡는 것이 어려웠습니다.
이번 과제의 조건이었던 '인스턴스 변수를 2개 이하로만 가지도록' 내용을 지키는 과정을 통해서 책임의 기준에 대해 고민하고 생각하는 과정을 연습할 수 있었지만 마지막까지 어렵게만 느껴졌습니다.
플레이어가 승패의 조건을 알기 위해서는 본인의 점수와 딜러의 점수를 알고있어야 판단이 가능했습니다. 하지만 플레이어가 딜러의 점수까지 알아야 하는가?를 생각했을 때 딜러의 점수까지 알아야 한다는 것은 플레이어에게 과한 책임이라고 생각하여 심판을 도입하게 되었습니다.
이처럼 특정 기능을 수행하기 위해서 요구되는 상황, 조건들을 생각해봤을 때 이것이 결코 해당 도메인이 가질수 있는 적절한 책임인가?를 기준으로 잡았었는데 틀리거나 보완할 부분이 있는지, 리뷰어님의 기준은 또 무엇인지 궁금합니다!
테스트의 범위
TDD 방식을 처음 시도하여 굉장히 낯설었습니다. 처음 Card 부분에서도 조언을 듣기전가지 isACE를 확인하는 테스트는 생각도 못했었습니다.
기능을 먼저 개발하고 테스트를 진행할 때에는 기능을 구현하던 과정에서 처리했던 예외를 확인해가며 테스트를 떠올리기 쉬웠는데,
반대로 테스트를 먼저 떠올리려고 하니 어떤 상황들이 발생할 수 있는지 그리기 어려웠습니다.
실제로 블랙잭을 참여하는 플레이어의 입장에서 전반적인 흐름을 생각해봤지만 그 안에 존재하는 단위테스트까지 완벽하게 캐치하지 못했습니다. 기능 구현을 생각하며 테스트를 작성하는 것은 뭔가 TDD 설계의 의도와는 맞지 않는 것 같은 느낌이었는데 리뷰어님께서는 TDD 설계를 어떻게 본인의 것으로 녹여내고 있는지 궁금합니다.