ReviewOS

also looking at this

craft-native/craft

feat(maps): add key-free native Android maps and shared map controls

#363
Merged chris wants to merge codex/wildloop-native-map-providers into main
28 files +1857 -481

Review threads live on the whole diff, not on one commit, so none are shown here - a thread's line means something in the branch's final form, and painting it into an intermediate step would put it on code it is not about.

packages/android/fixtures/native-navigation/NativeMapTest.ktmodified+6-2
Changes to packages/android/fixtures/native-navigation/NativeMapTest.kt
@@ -257,9 +257,13 @@ class NativeMapTest {
257257 }
258258 instrumentation.uiAutomation.waitForIdle(500, 5_000)
259259 assertNotEquals("The Home action must actually background the app", activity.packageName, instrumentation.uiAutomation.rootInActiveWindow?.packageName?.toString())
260 val resumed = instrumentation.startActivitySync(Intent(instrumentation.targetContext, MainActivity::class.java)
260 // startActivitySync waits for a new Activity creation; this Intent
261 // deliberately resumes the existing instance instead.
262 instrumentation.targetContext.startActivity(Intent(instrumentation.targetContext, MainActivity::class.java)
261263 .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_REORDER_TO_FRONT or Intent.FLAG_ACTIVITY_SINGLE_TOP))
262 assertSame("Returning must reuse the retained native map activity", activity, resumed)
264 awaitState("Returning must resume the retained native map activity") {
265 activity.lifecycle.currentState == androidx.lifecycle.Lifecycle.State.RESUMED && activity.hasWindowFocus()
266 }
263267 awaitState("The resumed native map must render its retained route and arrows") {
264268 features(map).size == 3 && map.queryRenderedFeatures(map.projection.toScreenLocation(LatLng(47.005, 11.005)), "craft-map-directions").isNotEmpty()
265269 }