summaryrefslogtreecommitdiff
path: root/tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp
diff options
context:
space:
mode:
authorDave Mankoff <mankoff@google.com>2021-06-15 10:11:35 -0400
committerDave Mankoff <mankoff@google.com>2021-07-15 13:53:53 -0400
commit4dda2323e9803de7c7f5d080389457d1128106ec (patch)
tree16e9ac5518363695864b843874f4f2c8264d2b81 /tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp
parented048c6a2a900e31ac1012224e87787b87b32df8 (diff)
New MessageRouter interface to replace Handler.
Proposal introduced in http://go/sysui-message-router This introduces a testable, controllerable MessageRouter interface intended to replace Handler#sendMessage. Listeners subscribe to specific messages rather than subclassing Handler. Also, metadata can be passed in any form, rather than the generic android.os.Message. To use, developers simply inject either an @Main or a @Background MessageRouter. This provides them with a new instance of a MessageRouter, tied to the corresponding Executor. As an example, the internal Handler subclass in GarbageMonitor has been replaced. There is an overall reduction in the number of lines of code, and the corresponding test has been refactored to be more deterministic and useful. Bug: 191077376 Test: atest SystemUITests Change-Id: Ibd1e05b1b5b7421c2085d8811b8f5cd61cf0ffde
Diffstat (limited to 'tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp')
0 files changed, 0 insertions, 0 deletions