Split the ReportUpdateAttemptMetrics into two functions

Move out the report download metrics into a new function so that
ReportUpdateAttemptMetrics has a reasonable number of parameters.
Create mocks for these two functions also.

Test: unittest pass
Change-Id: Ib9fc33d282a448c7e2d19bb7e7c06619efc2a278
diff --git a/payload_state.cc b/payload_state.cc
index 1f121b0..410a0bf 100644
--- a/payload_state.cc
+++ b/payload_state.cc
@@ -643,11 +643,13 @@
       duration,
       duration_uptime,
       payload_size,
+      attempt_result,
+      internal_error_code);
+
+  system_state_->metrics_reporter()->ReportUpdateAttemptDownloadMetrics(
       payload_bytes_downloaded,
       payload_download_speed_bps,
       download_source,
-      attempt_result,
-      internal_error_code,
       payload_download_error_code,
       attempt_connection_type_);
 }