Add FlushForTesting to InterfacePtr and Binding.

Previously, when unit testing a class that is a client of a mojo
interface, there was no reliable way to detect that no message was sent.
This adds a FlushForTesting() method to mojo message pipe bindings,
which can be used to wait for a round trip, after which any messages
already sent will have been delivered; this can be used to test for the
absence of messages sent in response to some stimulus.

Review-Url: https://codereview.chromium.org/2280483002
Cr-Commit-Position: refs/heads/master@{#415920}


CrOS-Libchrome-Original-Commit: 462458f4b533d44bfad95ea07dc99257eaf028cb
28 files changed
tree: 5288b3a505f5d266270932a0a65650166ebab15a
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/