-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat: Experiment on Graphics mode #61
base: main
Are you sure you want to change the base?
Conversation
Modify class instrumentor to allow use different graphics mode on the same sandbox
WalkthroughThe recent changes in the Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
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: 0
Review Details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (7)
- robolectric-extension/build.gradle (1 hunks)
- robolectric-extension/src/main/kotlin/org/robolectric/internal/bytecode/JUnit5RobolectricClassInstrumentor.kt (1 hunks)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5MavenDependencyResolver.kt (2 hunks)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricMavenArtifactFetcher.kt (1 hunks)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricSandboxManager.kt (2 hunks)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricTestRunner.kt (2 hunks)
- robolectric-extension/src/test/kotlin/tech/apter/junit/jupiter/robolectric/RobolectricExtensionGraphicsModeSelfTest.kt (1 hunks)
Files not reviewed due to errors (3)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5MavenDependencyResolver.kt (no review received)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricTestRunner.kt (no review received)
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricMavenArtifactFetcher.kt (no review received)
Files skipped from review due to trivial changes (2)
- robolectric-extension/build.gradle
- robolectric-extension/src/main/kotlin/tech/apter/junit/jupiter/robolectric/internal/JUnit5RobolectricSandboxManager.kt
Additional comments not posted (15)
robolectric-extension/src/test/kotlin/tech/apter/junit/jupiter/robolectric/RobolectricExtensionGraphicsModeSelfTest.kt (3)
23-30
: The test methodtest1Legacy
looks good and correctly verifies the shadow type for the legacy graphics mode.
32-38
: The test methodtest2NativeAfterLegacy
looks good and correctly verifies the shadow type for the native graphics mode.
40-46
: The test methodtest3LegacyAfterNative
looks good and correctly verifies the shadow type for the legacy graphics mode.robolectric-extension/src/main/kotlin/org/robolectric/internal/bytecode/JUnit5RobolectricClassInstrumentor.kt (12)
1-86
: Class declaration and companion object look good.
158-179
:analyzeClass
method looks good.
181-195
:instrumentToBytes
method looks good.
197-217
:instrument
method looks good.
219-226
:recordPackageStats
method looks good.
358-381
:instrumentMethods
method looks good.
384-407
:addNoArgsConstructor
method looks good.
420-449
:addRoboInitMethod
method looks good.
489-520
:instrumentConstructor
method looks good.
620-652
:instrumentNormalMethod
method looks good.
660-682
:instrumentNativeMethod
method looks good.
684-819
: Remaining methods and utility functions look good.
Modify class instrumentor to allow use different graphics mode on the same sandbox
Summary by CodeRabbit
New Features
Improvements
Bug Fixes
graphicsMode
property fromJUnit5RobolectricSandboxManager
constructor parameters.Refactor