From b903113570d6447024a565c160a442dd54090ef4 Mon Sep 17 00:00:00 2001 From: mhkeller Date: Tue, 26 Mar 2019 20:58:25 -0400 Subject: [PATCH] add test for calcextent --- test/calcExtents.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test/calcExtents.js b/test/calcExtents.js index 4ed87c7c..7e47d37c 100644 --- a/test/calcExtents.js +++ b/test/calcExtents.js @@ -31,6 +31,12 @@ const tests = [ {x: [-4, 0], y: [1, 6]}, {x: [-5, 1], y: [2, 7]}, {x: [-3, 2], y: [3, 8]}, {x: [-2, 3], y: [4, 9]}, {x: [-1, 4], y: [5, 10]} ], [{field: 'x', accessor: d => d.x}, {field: 'y', accessor: d => d.y}]], expected: {x: [-5, 4], y: [1, 10]} + }, + { + args: [[ + {start: 0, end: 1}, {start: -10000, end: 0} + ], [{field: 'y', accessor: d => [d.start, d.end]}]], + expected: {y: [-10000, 1]} } ];