-
Notifications
You must be signed in to change notification settings - Fork 2
스킬, 장비 아이템 업그레이드 시 최고 레벨일 경우 상태를 올바르게 수정하고, 테스트합니다. #269
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
Conversation
tomchoi95
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생 많으셨어요 소피!! 👍 👍
UI테스트 돌려봤는데 신기하네요!
dongglehada
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고 많으셨습니다 :>
UI테스트 신기하네요 👀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 확실히 최종단계 보다는 이게 더 좋은 것 같아요
| init(canUnlock: Bool, canAfford: Bool) { | ||
| if !canUnlock { | ||
| init(canUpgrade: Bool, canUnlock: Bool, canAfford: Bool) { | ||
| switch (canUpgrade, canUnlock, canAfford) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
switch 를 이렇게도 쓸 수 있군요
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
저도 처음 써보는 것 같네요 👀
| app.tap() | ||
| app.buttons["스킬"].tap() | ||
|
|
||
| let element = app.images.matching(identifier: "icon_coin_bag").element( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이미지로 매칭하는거 신기하네요
snughnu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
수고하셨습니다 소피 💃
연관된 이슈
작업 내용 및 고민 내용
스킬 업그레이드 버그 수정
canUpgrade로직을 추가하고, ItemState에reachedMax상태를 추가했습니다.UITest
해당 버그의 경우 개발자가 직접 100, 1000번의 버튼을 눌러보며 확인하면 번거롭기 때문에 UITest를 활용해볼 수 있다고 생각했습니다.
테스트 구현 과정
참고문서
Xcode에서 UI Testing Bundle을 추가하고, 빈 메서드를 생성합니다.
테스트 타깃으로 스킴을 설정한 뒤 Xcode Editor >
Start Recording UI Test를 클릭합니다.앱이 실행되면 화면 터치가 녹화되고, 자동으로 테스트가 상호작용하는 앱 내 요소를 찾아서 메서드에 기록해줍니다. 직접 요소 쿼리를 작성할 수는 있지만, UI 프레임워크의 요소 계층 구조에 익숙하지 않아 많은 시간이 소요되어 해당 방법을 사용했습니다.
앱 실행 -> 스킬 탭 -> 최고레벨까지 업그레이드플로우 녹화 후 자동 생성 결과위 코드를 직접 정리하여 최종적으로 현재 상태의 테스트 코드를 작성했습니다.
장비 업그레이드 버그 수정
Unit Test (오류 해결중)
Undefined Symbol ~오류를 해결하지 못해서 아직 테스트 결과는 확인하지 못했습니다 ㅠㅠ스크린샷
편의를 위해 임시로 policy를 수정한 상태로 촬영했습니다!
uitest 결과
\
장비 최고 단계 도달시 표시 모습
리뷰 요구사항