Include SDK sandbox process in package uid check
SDK sandbox processes created from the sandbox package do not have the
uid of the package - they use a separate uid range instead.
WindowManagerService.doesAddToastWindowRequireToken() does not take this
into account when run for the sandbox. This causes tests that use this
API to fail when run in the sandbox.
Instead, use the API PackageManagerService.isSameApp() that takes into
account the differences between sandbox package uid and sandbox process
uid.
Bug: 345469514
Test: atest ToastPresenterTest -- --enable-optional-parameterization --enable-parameterized-modules --module-parameter run_on_sdk_sandbox
Change-Id: I72362e635b134ef038a61c09d133551438aa3b86
1 file changed