Fix datachannel stats id and timestamp.
Makes the id now be "datachannel_#####" where '####' is the id number for the datachannel.
Adds a timestamp to the data channel reports.
Implements unit tests to verify that the timestamp is set correctly.
BUG=1805
R=juberti@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/33119004
Cr-Commit-Position: refs/heads/master@{#8236}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8236 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/talk/app/webrtc/statscollector.h b/talk/app/webrtc/statscollector.h
index 499da44..a4e42c9 100644
--- a/talk/app/webrtc/statscollector.h
+++ b/talk/app/webrtc/statscollector.h
@@ -97,6 +97,9 @@
private:
friend class StatsCollectorTest;
+ // Overridden in unit tests to fake timing.
+ virtual double GetTimeNow();
+
bool CopySelectedReports(const std::string& selector, StatsReports* reports);
// Helper method for AddCertificateReports.