From bf3553d56929de89062f0df08b286f5dde1f86eb Mon Sep 17 00:00:00 2001 From: morance Date: Fri, 28 Jun 2019 22:20:45 +0800 Subject: [PATCH] add the test suit --- tests/test-cases.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/test-cases.js b/tests/test-cases.js index eef1862..9d5be3a 100644 --- a/tests/test-cases.js +++ b/tests/test-cases.js @@ -1203,6 +1203,16 @@ var PARSE_TESTS = [ errors: [] } }, + { + description: "Pipe delimiter is guessed correctly choose avgFildCount max one", + notes: "Guessing the delimiter should work choose the min delta one and the max one", + config: {}, + input: 'a,b,c\na,b,c|d|e|f', + expected: { + data: [['a', 'b', 'c'], ['a','b','c|d|e|f']], + errors: [] + } + }, { description: "Pipe delimiter is guessed correctly when first field are enclosed in quotes and contain delimiter characters", notes: "Guessing the delimiter should work if the first field is enclosed in quotes, but others are not",