Conversation
…nstead of instrumented tests
b56f218 to
796c757
Compare
Contributor
There was a problem hiding this comment.
Pull Request Overview
Migrates Android tests to Robolectric-based unit tests to improve test execution speed and development workflow. The PR replaces instrumented tests with unit tests that can run on the JVM using Robolectric for Android framework mocking.
Key changes:
- Added Robolectric dependency and test runner configuration to all test classes
- Migrated tests from
androidTesttotestdirectory structure - Updated imports to use explicit references instead of wildcard imports
- Modified build configuration to support Robolectric unit tests
Reviewed Changes
Copilot reviewed 39 out of 52 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| lib/build.gradle.kts | Added Robolectric dependency and enabled Android resources for unit tests |
| gradle/libs.versions.toml | Added Robolectric version definition |
| lib/src/test/kotlin/at/bitfire/vcard4android/contactrow/*.kt | Added @RunWith(RobolectricTestRunner::class) annotations and import cleanup |
| lib/src/test/kotlin/at/bitfire/synctools/**/*.kt | Converted tests to use Robolectric with proper imports |
| lib/src/test/kotlin/at/bitfire/ical4android/**/*.kt | Migrated various utility and core tests to Robolectric |
| lib/src/androidTest/kotlin/at/bitfire/ical4android/Css3ColorTest.kt | Moved from androidTest to test directory |
Comments suppressed due to low confidence (1)
lib/src/test/kotlin/at/bitfire/ical4android/LocaleNonWesternDigitsTest.kt:47
- Using
String.Companion.formatis unnecessarily verbose. UseString.formatdirectly as it's a static method.
Assert.assertEquals("2020", String.Companion.format(Locale.ROOT, "%d", 2020))
lib/src/test/kotlin/at/bitfire/vcard4android/LocaleNonWesternDigitsTest.kt
Outdated
Show resolved
Hide resolved
lib/src/test/kotlin/at/bitfire/synctools/mapping/calendar/AttendeeMappingsTest.kt
Outdated
Show resolved
Hide resolved
fa5d0cb to
602b4c7
Compare
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.
No description provided.