| 383 | } |
| 384 | |
| 385 | void TestReader::testReadFileWithEmptyFields() |
| 386 | { |
| 387 | const QString path = getPathToFileWithEmptyFields(); |
| 388 | QList<QStringList> data = QtCSV::Reader::readToList(path, ",", "\""); |
| 389 | QVERIFY2(false == data.isEmpty(), "Failed to read file content"); |
| 390 | |
| 391 | QList<QStringList> expected; |
| 392 | expected << (QStringList() << QString() << "0" << QString() << QString()); |
| 393 | |
| 394 | QVERIFY2(expected.size() == data.size(), "Wrong number of rows"); |
| 395 | for (int i = 0; i < data.size(); ++i) |
| 396 | { |
| 397 | QVERIFY2(expected.at(i) == data.at(i), "Wrong row data"); |
| 398 | } |
| 399 | } |
| 400 | |
| 401 | void TestReader::testReadFileWithEmptyFieldsComplexSeparator() |
| 402 | { |
nothing calls this directly
no test coverage detected