diff data/fileio/test/CSVFormatTest.h @ 1599:ce185d4dd408 bqaudiostream

Merge from default branch
author Chris Cannam
date Wed, 23 Jan 2019 14:43:43 +0000
parents 9570ef94eaa3
children 1b8c4ee06f6d
line wrap: on
line diff
--- a/data/fileio/test/CSVFormatTest.h	Wed Jan 23 10:31:40 2019 +0000
+++ b/data/fileio/test/CSVFormatTest.h	Wed Jan 23 14:43:43 2019 +0000
@@ -91,6 +91,18 @@
         QCOMPARE(f.getColumnCount(), 3);
     }
     
+    void plausibleSeparators() {
+        CSVFormat f;
+        QVERIFY(f.guessFormatFor(csvDir.filePath("separator-many.csv")));
+        std::set<QChar> p;
+        p.insert(QChar('|'));
+        p.insert(QChar(','));
+        p.insert(QChar(':'));
+        p.insert(QChar(' '));
+        std::set<QChar> actual = f.getPlausibleSeparators();
+        QCOMPARE(actual, p);
+    }
+    
     void comment() {
         CSVFormat f;
         QVERIFY(f.guessFormatFor(csvDir.filePath("comment.csv")));