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

Unified Diff: tracing/tracing/base/math/statistics_test.html

Issue 2776653002: [ESLint] Fix violations when enabling curly rule in eslint. (Closed)
Patch Set: rebase Created 3 years, 9 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 | « tracing/tracing/base/math/statistics.html ('k') | tracing/tracing/base/multi_dimensional_view.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/base/math/statistics_test.html
diff --git a/tracing/tracing/base/math/statistics_test.html b/tracing/tracing/base/math/statistics_test.html
index f9ad8d982d64d0453170938bf326987ae307d118..af0974f6c272d2114153510f97a7e97e1e84dc9c 100644
--- a/tracing/tracing/base/math/statistics_test.html
+++ b/tracing/tracing/base/math/statistics_test.html
@@ -23,8 +23,9 @@ tr.b.unittest.testSuite(function() {
opt_iterations = opt_iterations || 10;
for (var i = 0; i < opt_iterations; i++) {
var voronoiBoundaries = [];
- for (var j = 1; j < samples.length; j++)
+ for (var j = 1; j < samples.length; j++) {
voronoiBoundaries.push((samples[j] + samples[j - 1]) * 0.5);
+ }
var relaxedSamples = [];
relaxedSamples.push(samples[0]);
@@ -165,14 +166,16 @@ tr.b.unittest.testSuite(function() {
assert.closeTo(6, Statistics.geometricMean(new Set([4, 9])), 1e-6);
var samples = [];
- for (var i = 0; i < 1e3; ++i)
+ for (var i = 0; i < 1e3; ++i) {
samples.push(Number.MAX_SAFE_INTEGER);
+ }
assert.closeTo(Number.MAX_SAFE_INTEGER, Statistics.geometricMean(samples),
Number.MAX_SAFE_INTEGER * 1e-13);
samples = [];
- for (var i = 0; i < 1e3; ++i)
+ for (var i = 0; i < 1e3; ++i) {
samples.push(Number.MAX_VALUE / 1e3);
+ }
assert.closeTo(Number.MAX_VALUE / 1e3, Statistics.geometricMean(samples),
Number.MAX_VALUE * 1e-13);
});
« no previous file with comments | « tracing/tracing/base/math/statistics.html ('k') | tracing/tracing/base/multi_dimensional_view.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698