Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(552)

Unified Diff: remoting/webapp/base/js/session_logger_unittest.js

Issue 2913073002: Stops accumulating performance statistics on the Chrome App. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/webapp/base/js/session_logger.js ('k') | remoting/webapp/base/js/stats_accumulator.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/base/js/session_logger_unittest.js
diff --git a/remoting/webapp/base/js/session_logger_unittest.js b/remoting/webapp/base/js/session_logger_unittest.js
index 460dec55ddd12d4383d8c6675f50a12121edf2d3..c1d55b45716e77476d8318287ad8519aab4b4b19 100644
--- a/remoting/webapp/base/js/session_logger_unittest.js
+++ b/remoting/webapp/base/js/session_logger_unittest.js
@@ -277,36 +277,19 @@ QUnit.test('logStatistics()', function(assert) {
logger.setConnectionType('direct');
logger.setHost(fakeHost);
- // Log the statistics.
- logger.logStatistics({
- videoBandwidth: 1.0,
- captureLatency: 1.0,
- encodeLatency: 1.0,
- decodeLatency: 0.0,
- renderLatency: 1.0,
- roundtripLatency: 1.0
- });
-
- logger.logStatistics({
- videoBandwidth: 2.0,
- captureLatency: 2.0,
- encodeLatency: 1.0,
- decodeLatency: 0.0,
- renderLatency: 2.0,
- roundtripLatency: 2.0
- });
-
- sinon.assert.notCalled(logWriterSpy);
- // Stats should only be accumulated at |CONNECTION_STATS_ACCUMULATE_TIME|.
- clock.tick(remoting.SessionLogger.CONNECTION_STATS_ACCUMULATE_TIME + 10);
-
+ // Log the statistics
logger.logStatistics({
videoBandwidth: 3.0,
- captureLatency: 3.0,
- encodeLatency: 1.0,
- decodeLatency: 0.0,
- renderLatency: 0.0,
- roundtripLatency: 0.0
+ captureLatency: 1.0,
+ maxCaptureLatency: 3.0,
+ encodeLatency: 2.0,
+ maxEncodeLatency: 4.0,
+ decodeLatency: 3.0,
+ maxDecodeLatency: 5.0,
+ renderLatency: 4.0,
+ maxRenderLatency: 6.0,
+ roundtripLatency: 5.0,
+ maxRoundtripLatency: 7.0
});
verifyEvent(assert, 0, {
@@ -323,12 +306,17 @@ QUnit.test('logStatistics()', function(assert) {
host_os: remoting.ChromotingEvent.Os.OTHER,
host_os_version: 'host_os_version',
session_id: logger.getSessionId(),
- video_bandwidth: 2.0,
- capture_latency: 2.0,
- encode_latency: 1.0,
- decode_latency: 0.0,
- render_latency: 1.0,
- roundtrip_latency: 1.0
+ video_bandwidth: 3.0,
+ capture_latency: 1.0,
+ encode_latency: 2.0,
+ decode_latency: 3.0,
+ render_latency: 4.0,
+ roundtrip_latency: 5.0,
+ max_capture_latency: 3.0,
+ max_encode_latency: 4.0,
+ max_decode_latency: 5.0,
+ max_render_latency: 6.0,
+ max_roundtrip_latency: 7.0
});
});
@@ -349,17 +337,6 @@ QUnit.test('logStatistics() should not log if all stats are zeros ',
roundtripLatency: 0.0
});
- clock.tick(remoting.SessionLogger.CONNECTION_STATS_ACCUMULATE_TIME + 10);
-
- logger.logStatistics({
- videoBandwidth: 0.0,
- captureLatency: 0.0,
- encodeLatency: 0.0,
- decodeLatency: 0.0,
- renderLatency: 0.0,
- roundtripLatency: 0.0
- });
-
sinon.assert.notCalled(logWriterSpy);
});
« no previous file with comments | « remoting/webapp/base/js/session_logger.js ('k') | remoting/webapp/base/js/stats_accumulator.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698