Fix & speed up IntentForwarderActivityTest

IntentForwarderActivityTest was waiting for 30 seconds for each test
because it awaited an executor shutdown that it never requested.  Fixing
this exposed some race conditions that were being hidden by the delay.

Also:
- Injecting device provisioning bool instead of writing to global
settings in the test.
- Add android.permission.HIDE_OVERLAY_WINDOWS, otherwise
IntentForwarderActivity crashes when it calls setHideOverlayWindows() in
the test.
- Fix some assertions that were backwards (asserting null on
something that had to be non-null for the other lines to pass).
- Re-enable the test

Bug: 410925936
Test: atest IntentForwarderActivityTest
Flag: EXEMPT TEST_ONLY
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:7722192034b5aa341b46cf7803bad3050cf6a054
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:6354e06830d76c34a05963ac0e3dade4d4bc9969
Merged-In: Iade781e0758c477ca888bd1541e0c53e2dee3761
Change-Id: Iade781e0758c477ca888bd1541e0c53e2dee3761
4 files changed