[android] Fix some tests for AOSP-master devices.

Some tests are broken at API level 30 on AOSP-master devices. When we
change the buildbuit to API level 30, the following tests get enabled.
They're currently broken due to various issues, and so fix up those
issues.

Reviewed By: oontvoo, eugenis

Differential Revision: https://reviews.llvm.org/D94100

GitOrigin-RevId: 1f8031cd74887025a5de1e7129718186369db769
3 files changed