FrameworkFacade: add helper to ease testing

WifiController, RecommendedNetworkEvaluator and SavedNetworkEvaluator
all use ContentObservers in their implementations.  The tests for these
classes started failing when a change was made to include the Context
object when registering ContentObservers.  This changed caused the tests
for these methods to fail due to a mix of mocks and actual objects.
This CL adds a helper to FrameworkFacade that allow the tests to pass,
and even better, updates them to use ArgumentCaptors to get a handle on
the ContentObservers.  This will allow the tests to be enhanced and
easily call the observers to test functionality for changes related to
the observers.

Bug: 35908602
Test: frameworks/base/wifi/tests/runtests.sh
Test: frameworks/opt/net/wifi/tests/wifitests/runtests.sh
Change-Id: I2e4a39febf575c1335cec57b9e21e28cb3e0fffd
7 files changed
tree: d400e4bfcf2889cbb9023b57ad4b07a524e2f711
  1. libwifi_hal/
  2. libwifi_system/
  3. service/
  4. tests/
  5. PREUPLOAD.cfg