Merge changes I0613c23f,Ibeab8d0a,I8bd668ad,I7d3a16be

* changes:
  [NS A14] Move code notifying battery stats in its right place
  [NS A13] Move legacy broadcast handling after rematch.
  [NS A12] Move some legacy type tracker handling to a function
  Add tests for ConnectivityService → BatteryStats messages