Also fixes an infinite recursion when invoking
TestableContext.(un)registerComponentCallbacks().
Test: atest WindowInsetsPolicyTest
Bug: 126511573
Change-Id: I5c9f40054493a83746bce6124d72412e8eb8a0d1
This just tests the standard progression into deep idle mode. Exit
conditions and light idle flow is not tested yet.
Bug: 116512267
Test: atest com.android.server.DeviceIdleControllerTest
Change-Id: I015c10871cd00d7a6be19c0b13fd4b3926c9fdf0
Makes it easy to add or change values of resources from tests.
Test: runtest --path frameworks/base/tests/testables/tests
Change-Id: Iaedff3d4ce9eaf9f270e7c62bc8c1634bd3519ec
Instead of just having random tests fail, fail all the tests with a
slightly more useful message.
Also remove all the code around acquiring and contention, now that
we have a test rule in place for TestableContext, we can just use
that for cleanup and have a simple copy-on-write provider.
Test: runtest -x frameworks/base/tests/testables && runtest systemui
Change-Id: I907da23730a4a96cfa2bb112100a06980f01b078
Fixes: 37302051