Android Unit Testing Framework
This report summarizes scanner evidence for robolectric/robolectric, a Java project with 6,075 GitHub stars. SynthScan examined 413,856 lines of code across 2693 source files, recording 299 pattern matches distributed across 8 syntactic categories. The legacy adjusted pattern signal is 0.9 (Low pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Payload schema: 1.0.0 · Engine: 2.0.0 · Scoring: heuristic-density-v1 · Scan date: 2026-10-31.
Can maintainers explain intent, assumptions, and trade-offs? 284 finding(s).
Are imports declared and package/API names verified? 15 finding(s).
Are wrappers, guards, and repeated structures necessary? 0 finding(s).
Which changes need focused human review? 299 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 299 distinct pattern matches across 8 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …va/org/robolectric/shadows/ShadowArscAssetManager.java | 1141 | COMMENT | |
| LOW | …va/org/robolectric/shadows/ShadowArscAssetManager.java | 1301 | final Ref<ResTable_config> config = new Ref<>(new ResTable_config()); | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowLegacyCursorWindow.java | 321 | COMMENT | |
| LOW | …n/java/org/robolectric/shadows/ShadowImageDecoder.java | 141 | imgStream.isNinePatch()); | COMMENT |
| LOW | …n/java/org/robolectric/shadows/ShadowImageDecoder.java | 161 | // SkFILEStream fileStream(new SkFILEStream(file)); | COMMENT |
| LOW | …src/main/java/org/robolectric/shadows/NativeInput.java | 241 | * Key events. | COMMENT |
| LOW | …src/main/java/org/robolectric/shadows/NativeInput.java | 261 | // int source, | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowVectorDrawable.java | 21 | import android.graphics.drawable.VectorDrawable; | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowVectorDrawable.java | 141 | path.strokeLineJoin = strokeLineJoin; | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowVectorDrawable.java | 221 | group.pivotX = pivotX; | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowVectorDrawable.java | 241 | // private static native float nGetPivotX(long groupPtr); | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowVectorDrawable.java | 261 | // private static native void nSetStrokeAlpha(long pathPtr, float alpha); | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 121 | // #include <sys/types.h> | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 141 | // #include "nativehelper/ScopedPrimitiveArray.h" | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 161 | // jfieldID mData; | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 181 | // }; | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 241 | return; | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 261 | // PLOG(ERROR) << "capget"; | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 281 | // // Generic idmap parameters | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 301 | // } | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1761 | @Implementation(minSdk = P) | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1781 | // {"nativeList", "(JLjava/lang/String;)[Ljava/lang/String;", (void*)NativeList}, | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1801 | // {"nativeGetResourceArray", "(JI[I)I", (void*)NativeGetResourceArray}, | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1821 | // {"nativeThemeCreate", "(J)J", (void*)NativeThemeCreate}, | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1841 | // {"nativeVerifySystemIdmaps", "()V", (void*)NativeVerifySystemIdmaps}, | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1861 | // GetFieldIDOrDie(env, typedValue, "changingConfigurations", "I"); | COMMENT |
| LOW | …/org/robolectric/shadows/ShadowArscAssetManager10.java | 1881 | // gSparseArrayOffsets.put = | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 801 | COMMENT | |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 821 | // AINPUT_MOTION_RANGE_TOUCH_MAJOR = AMOTION_EVENT_AXIS_TOUCH_MAJOR; | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 841 | // * | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 861 | // */ | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 881 | // * Note that when chording keys, this value is the down time of the most recently | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 901 | // /** Get the button state of all buttons that are pressed. */ | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 921 | // * Get the X coordinate offset. | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 941 | // * Get the precision of the Y coordinates being reported. | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 961 | // * The tool type indicates the type of tool used to make contact such as a | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 981 | // * Get the current X coordinate of this event for the given pointer index. | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1001 | // * This represents some approximation of the area of the screen being | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1021 | // * The tool area represents the estimated size of the finger or pen that is | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1041 | // */ | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1061 | // /** | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1081 | // float AMotionEvent_getHistoricalRawY(const AInputEvent* motion_event, size_t pointer_index, | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1101 | // * occurred between this event and the previous motion event. | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1121 | // * Get the historical length of the major axis of an ellipse that describes the touch area | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1141 | // * touching the device independent of its actual touch area at the point of contact. | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1161 | // * upwards, is perfectly circular or is of unknown orientation. A positive angle | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1181 | // * | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1201 | // int32_t AInputQueue_hasEvents(AInputQueue* queue); | COMMENT |
| LOW | …n/java/org/robolectric/shadows/NativeAndroidInput.java | 1221 | // #ifdef __cplusplus | COMMENT |
| LOW | …ava/org/robolectric/shadows/ShadowLocationManager.java | 1481 | } | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowArscApkAssets9.java | 41 | minSdk = P, | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowArscApkAssets9.java | 181 | } | COMMENT |
| LOW | …java/org/robolectric/shadows/ShadowArscApkAssets9.java | 281 | // (void*)NativeLoadFromFd}, | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 101 | private static long systemCppAssetManager2Ref; | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 121 | // #include "android-base/logging.h" | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 141 | // #include "utils/String.h" | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 161 | // jfieldID mDensity; | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 181 | // jfieldID native_ptr; | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 241 | // PLOG(ERROR) << "failed to fork for idmap"; | COMMENT |
| LOW | …a/org/robolectric/shadows/ShadowArscAssetManager9.java | 261 | // if (capset(&capheader, &capdata) != 0) { | COMMENT |
| 210 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| CRITICAL | …java/org/robolectric/shadows/ShadowPackageManager.java | 675 | // From com.android.server.pm.PackageManagerService.compareSignatures(). | COMMENT |
| CRITICAL | …notation/processing/ksp/RobolectricKspProcessorTest.kt | 265 | assertThat(contentVisible).contains("return org.robolectric.shadow.api.Shadow.extract(actual);") | CODE |
| CRITICAL | …tric/annotation/processing/ksp/ShadowProviderWriter.kt | 159 | output.writeText(" return org.robolectric.shadow.api.Shadow.extract(actual);\n") | CODE |
| CRITICAL | …ic/annotation/processing/RobolectricProcessorTest.java | 204 | com.google.common.io.Resources.asByteSource( | CODE |
| CRITICAL | …ic/annotation/processing/RobolectricProcessorTest.java | 205 | com.google.common.io.Resources.getResource( | CODE |
| CRITICAL | …g/robolectric/util/reflector/ReflectorClassWriter.java | 548 | return org.objectweb.asm.commons.Method.getMethod(method); | CODE |
| CRITICAL | …g/robolectric/util/reflector/ReflectorClassWriter.java | 556 | this(org.objectweb.asm.commons.Method.getMethod(method), method); | CODE |
| CRITICAL | …ric/src/test/java/org/robolectric/RobolectricTest.java | 156 | ClassLoader loader = android.content.res.ColorStateList.class.getClassLoader(); | CODE |
| CRITICAL | …a/org/robolectric/shadows/ShadowBitmapFactoryTest.java | 529 | InputStream inputStream = com.google.common.io.Resources.getResource(imagePath).openStream(); | CODE |
| CRITICAL | …a/org/robolectric/shadows/ShadowBitmapFactoryTest.java | 567 | return toByteArray(com.google.common.io.Resources.getResource(imagePath)); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …java/org/robolectric/shadows/ShadowLegacyTypeface.java | 212 | // TODO: implement this properly | COMMENT |
| LOW | …rg/robolectric/shadows/BluetoothGattProxyDelegate.java | 153 | // TODO: implement properly | COMMENT |
| LOW | …in/java/org/robolectric/shadows/ShadowFontBuilder.java | 125 | // TODO: implement | COMMENT |
| LOW | …in/java/org/robolectric/res/android/ResourceTypes.java | 1207 | // TODO: implement above | COMMENT |
| LOW | …/main/java/org/robolectric/res/android/LoadedArsc.java | 535 | // TODO: implement above | COMMENT |
| LOW | …/java/org/robolectric/res/android/CppAssetManager.java | 138 | // TODO: implement this? | COMMENT |
| LOW | …/java/org/robolectric/res/android/CppAssetManager.java | 272 | // TODO: implement this? | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …/robolectric/shadows/ShadowNativeStaticLayoutTest.java | 93 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW | …/robolectric/shadows/ShadowNativeStaticLayoutTest.java | 93 | "Lorem ipsum dolor sit amet, consectetur adipiscing " | CODE |
| LOW⚡ | …bolectric/junit/rules/ExpectedLogMessagesRuleTest.java | 64 | final Throwable throwable = new Throwable("lorem ipsum"); | CODE |
| LOW⚡ | …bolectric/junit/rules/ExpectedLogMessagesRuleTest.java | 71 | final IllegalArgumentException exception = new IllegalArgumentException("lorem ipsum"); | CODE |
| LOW⚡ | …bolectric/junit/rules/ExpectedLogMessagesRuleTest.java | 79 | final Throwable throwable = new Throwable("lorem ipsum"); | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | scripts/install-android-prebuilt.sh | 7 | # Usage: | COMMENT |
| LOW | scripts/deploy-android.sh | 5 | # Usage: | COMMENT |
| LOW | scripts/build-android.sh | 7 | # Usage: | COMMENT |
| LOW | scripts/sync-android.sh | 5 | # Usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | .github/workflows/codeql.yml | 57 | # If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …java/org/robolectric/res/android/CppAssetManager2.java | 1542 | // NOTE: This function does not do reference traversal. If you want to follow references to | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | …rc/main/java/org/robolectric/res/android/ResTable.java | 1234 | // TODO(BC): The following code block was a best effort attempt to directly transliterate | COMMENT |