X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=auto_tests%2Ftests%2Fto_dom_coords.js;h=5bfab1ba254b23238775b5643baeca51ea0db503;hb=bfb3e0a44ba7eb76704389cd1515db9995944d41;hp=70518a1055767b134f63e7998c64a78984f70b65;hpb=a0d2e89b1cc62ad1e6a3bf0211e303030c52663e;p=dygraphs.git diff --git a/auto_tests/tests/to_dom_coords.js b/auto_tests/tests/to_dom_coords.js index 70518a1..5bfab1b 100644 --- a/auto_tests/tests/to_dom_coords.js +++ b/auto_tests/tests/to_dom_coords.js @@ -69,13 +69,19 @@ ToDomCoordsTestCase.prototype.testPlainChart = function() { ToDomCoordsTestCase.prototype.testChartWithAxes = function() { var opts = { - drawXAxis: true, + axes : { + x : { + drawGrid: false, + drawAxis: true, + }, + y : { + drawGrid: false, + drawAxis: true, + axisLabelWidth: 100 + } + }, xAxisHeight: 50, - drawYAxis: true, - yAxisLabelWidth: 100, axisTickSize: 0, - drawXGrid: false, - drawYGrid: false, rightGap: 0, valueRange: [0, 100], dateWindow: [0, 100], @@ -97,13 +103,19 @@ ToDomCoordsTestCase.prototype.testChartWithAxes = function() { ToDomCoordsTestCase.prototype.testChartWithAxesAndLabels = function() { var opts = { - drawXAxis: true, + axes : { + x : { + drawGrid: false, + drawAxis: true, + }, + y : { + drawGrid: false, + drawAxis: true, + axisLabelWidth: 100 + } + }, xAxisHeight: 50, - drawYAxis: true, - yAxisLabelWidth: 100, axisTickSize: 0, - drawXGrid: false, - drawYGrid: false, rightGap: 0, valueRange: [0, 100], dateWindow: [0, 100], @@ -130,7 +142,7 @@ ToDomCoordsTestCase.prototype.testChartWithAxesAndLabels = function() { ToDomCoordsTestCase.prototype.testYAxisLabelWidth = function() { var opts = { - yAxisLabelWidth: 100, + axes: { y: { axisLabelWidth: 100 } }, axisTickSize: 0, rightGap: 0, valueRange: [0, 100], @@ -145,14 +157,16 @@ ToDomCoordsTestCase.prototype.testYAxisLabelWidth = function() { assertEquals([100, 0], g.toDomCoords(0, 100)); assertEquals([500, 486], g.toDomCoords(100, 0)); - g.updateOptions({ yAxisLabelWidth: 50 }); + g.updateOptions({ + axes: { y: { axisLabelWidth: 50 }}, + }); assertEquals([50, 0], g.toDomCoords(0, 100)); assertEquals([500, 486], g.toDomCoords(100, 0)); } ToDomCoordsTestCase.prototype.testAxisTickSize = function() { var opts = { - yAxisLabelWidth: 100, + axes: { y: { axisLabelWidth: 100 } }, axisTickSize: 0, rightGap: 0, valueRange: [0, 100],