From: Robert Konigsberg Date: Fri, 27 Sep 2013 14:30:58 +0000 (-0400) Subject: Code comments and indentation fixes. X-Git-Tag: v1.1.0~82^2 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=refs%2Fheads%2Fconnect-separated-points;p=dygraphs.git Code comments and indentation fixes. --- diff --git a/auto_tests/tests/CanvasAssertions.js b/auto_tests/tests/CanvasAssertions.js index 62a3f49..9550912 100644 --- a/auto_tests/tests/CanvasAssertions.js +++ b/auto_tests/tests/CanvasAssertions.js @@ -185,6 +185,9 @@ CanvasAssertions.numLinesDrawn = function(proxy, color) { var num_lines = 0; for (var i = 0; i < proxy.calls__.length; i++) { var call = proxy.calls__[i]; + + // note: Don't simplify these two conditionals into one. The + // separation simplifies debugging tricky tests. if (call.name == "lineTo") { if (call.properties.strokeStyle == color) { num_lines++; diff --git a/auto_tests/tests/connect_separated_points.js b/auto_tests/tests/connect_separated_points.js index f668ebc..95ef88e 100644 --- a/auto_tests/tests/connect_separated_points.js +++ b/auto_tests/tests/connect_separated_points.js @@ -363,20 +363,20 @@ ConnectSeparatedPointsTestCase.prototype.testConnectSeparatedPointsPerSeries = f } var g = new Dygraph(document.getElementById("graph"), - [ - [1, 10, 10, 10], - [2, 15, 11, 12], - [3, null, null, 12], - [4, 20, 14, null], - [5, 15, null, 17], - [6, 18, null, null], - [7, 12, 14, null] - ], - { - labels: ["Date","Series1","Series2","Series3"], - connectSeparatedPoints: false, - colors: ["#ff0000", "#00ff00", "#0000ff"] - }); + [ + [1, 10, 10, 10], + [2, 15, 11, 12], + [3, null, null, 12], + [4, 20, 14, null], + [5, 15, null, 17], + [6, 18, null, null], + [7, 12, 14, null] + ], + { + labels: ["Date","Series1","Series2","Series3"], + connectSeparatedPoints: false, + colors: ["#ff0000", "#00ff00", "#0000ff"] + }); htx = g.hidden_ctx_; assertExpectedLinesDrawnPerSeries(htx, 4, 1, 2);