Fix MultiDisplayVeiledResizeTaskPositionerTest failure
Kotlin 2.0 enforces stricter NonNull requirements, causing tests related to `SurfaceControl.Transaction#setPosition` to fail. These tests previously passed with Kotlin 1.9 without explicitly handling the return value of `setPosition`, which now requires returning a NonNull object. This commit fixes the failing tests by explicitly returning the mocked `Transaction` object when `setPosition` is called. And updated the source code to use getLeash instead of directly getting `mTaskSurface` in order to hijack the `setPosition` call. Bug: 391717499 Test: atest Flag: EXEMPT unblock presubmit Change-Id: I081b6e7695aaba6d745d559b548eaa8b66b51d1f
Loading
Please register or sign in to comment