-
Notifications
You must be signed in to change notification settings - Fork 1
[FEATURE] Benchmark Host Activity 생성 #276
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
Walkthrough벤치마크 전용 호스트 액티비티를 생성하고 관련 인프라를 구성합니다. BenchmarkHostActivity는 인텐트 엑스트라를 통해 특정 벤치마크 화면을 동적으로 라우팅하며, OrbitPicker 컴포넌트에 대한 벤치마크 화면과 macrobenchmark 테스트가 추가됩니다. Changes
Sequence Diagram(s)sequenceDiagram
participant Test as MacrobenchmarkRule
participant Activity as BenchmarkHostActivity
participant Router as BenchmarkScreenContainer
participant Screen as OrbitPickerBenchmarkScreen
Test->>Activity: startActivity (EXTRA_BENCHMARK_SCREEN)
Activity->>Activity: readExtra (benchmark_screen_key)
Activity->>Router: BenchmarkScreenContainer(screenKey)
alt screenKey == "orbit_picker"
Router->>Screen: OrbitPickerBenchmarkScreen()
Screen->>Screen: Initialize state (selectedTime, drawn)
Screen->>Screen: ReportDrawnWhen(drawn)
Screen->>Screen: Render OrbitPicker + LaunchedEffect
else screenKey unknown
Router->>Router: BenchmarkScreenMissing(screenKey)
Router->>Router: Display error state
end
Test->>Test: Measure frame timing
Test->>Test: Perform swipe gesture
Test->>Test: Wait for idle
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10분
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 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.
Actionable comments posted: 1
🧹 Nitpick comments (2)
app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/BenchmarkHostActivity.kt (1)
20-61: 벤치마크 호스트 라우팅 구조가 단순하고 확장 가능하게 잘 잡혀 있습니다
EXTRA_BENCHMARK_SCREEN키로 단일 Activity에서 벤치마크 스크린을 스위치하는 구조와, 미등록 키에 대해BenchmarkScreenMissing을 보여주는 처리가 디버깅에도 도움이 될 것 같습니다. 스크린 키가 더 늘어날 경우를 대비해 sealed class/enum 등으로 키를 묶는 것도 고려해볼 수 있지만, 현재 규모에서는 지금처럼 단순한when분기가 가독성과 유지 보수 측면에서 충분해 보입니다.baselineprofile/src/main/java/com/dongchyeon/baselineprofile/OrbitPickerBenchmarks.kt (1)
25-75: Baseline Profile 모드 고정 여부를 한 번 고민해 볼 만합니다현재는
CompilationMode.Partial()을 그대로 사용하고 있어서, 베이스라인 프로파일이 누락된 상태에서도 테스트가 그대로 통과할 수 있습니다. 베이스라인 프로파일이 실제로 적용되지 않은 경우를 확실히 잡아내고 싶다면CompilationMode.Partial(baselineProfileMode = BaselineProfileMode.Require)형태로 실패를 강제하는 옵션도 고려해 보셔도 좋겠습니다; 그런 요구가 없다면 지금 구현만으로도 벤치마크 자체는 충분히 목적에 부합해 보입니다.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
app/build.gradle.kts(1 hunks)app/src/benchmarkRelease/AndroidManifest.xml(1 hunks)app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/BenchmarkHostActivity.kt(1 hunks)app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/OrbitPickerBenchmarkScreen.kt(1 hunks)baselineprofile/src/main/java/com/dongchyeon/baselineprofile/OrbitPickerBenchmarks.kt(1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-07-16T14:32:09.264Z
Learnt from: DongChyeon
Repo: YAPP-Github/Orbit-Android PR: 233
File: domain/src/main/java/com/yapp/domain/usecase/AlarmUseCase.kt:38-61
Timestamp: 2025-07-16T14:32:09.264Z
Learning: In the Orbit-Android project, the team prefers to focus unit testing on core business logic rather than UseCase wrapper methods to avoid unnecessary dependency mocking costs. They consider it sufficient to test the main formatting logic (like formatTimeDifference) rather than testing thin wrapper methods in UseCases.
Applied to files:
baselineprofile/src/main/java/com/dongchyeon/baselineprofile/OrbitPickerBenchmarks.ktapp/src/benchmarkRelease/java/com/yapp/orbit/benchmark/OrbitPickerBenchmarkScreen.kt
🧬 Code graph analysis (2)
app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/OrbitPickerBenchmarkScreen.kt (2)
core/ui/src/main/java/com/yapp/ui/component/timepicker/OrbitPicker.kt (1)
OrbitPicker(39-167)core/designsystem/src/main/java/com/yapp/designsystem/theme/Theme.kt (1)
OrbitTheme(12-28)
app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/BenchmarkHostActivity.kt (2)
core/designsystem/src/main/java/com/yapp/designsystem/theme/Theme.kt (1)
OrbitTheme(12-28)app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/OrbitPickerBenchmarkScreen.kt (1)
OrbitPickerBenchmarkScreen(28-60)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build
🔇 Additional comments (2)
app/src/benchmarkRelease/AndroidManifest.xml (1)
4-10: Benchmark 전용 Activity export 설정은 적절해 보입니다
BenchmarkHostActivity를 별도benchmarkRelease매니페스트에서android:exported="true"로만 노출한 점이 Macrobenchmark 용도로는 적절해 보입니다. 다만 이 variant가 실제 스토어 배포용 빌드 구성에 포함되지 않는지만(내부/벤치마크 전용인지) 한 번만 빌드 설정을 확인해 두시면 안전할 것 같습니다.app/src/benchmarkRelease/java/com/yapp/orbit/benchmark/OrbitPickerBenchmarkScreen.kt (1)
28-60: OrbitPicker 벤치마크 스크린 구성이 테스트 시나리오에 잘 맞습니다선택된 시간 state,
ReportDrawnWhen기반 프레임 완료 신호, 그리고contentDescription = ORBIT_PICKER_BENCHMARK_ROOT설정이 baselineprofile 쪽 상수("orbit_picker_root")와 정확히 매칭되어 있어서, 매크로벤치마크에서 대상 뷰 탐색과 스크롤 제스처 측정이 안정적으로 동작할 것으로 보입니다.
Related issue 🛠
closed #275
어떤 변경사항이 있었나요?
CheckPoint ✅
PR이 다음 요구 사항을 충족하는지 확인하세요.
Work Description ✏️
OrbitPicker (타임피커) 개선 전(aed700e) 과 개선 후 벤치마크 결과
P50 성능 비교표
Uncompleted Tasks 😅
N/A
To Reviewers 📢
Summary by CodeRabbit
릴리스 노트
✏️ Tip: You can customize this high-level summary in your review settings.