summaryrefslogtreecommitdiffstats
path: root/tests/testparse.cpp
diff options
context:
space:
mode:
authorGravatar Miika Turkia <miika.turkia@gmail.com>2017-11-26 10:48:03 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-11-27 13:42:10 -0800
commite17ad1b0e03f49160d397f84bab8b9251d555d26 (patch)
tree726054aeea794935c427c08c4469437e22af55fa /tests/testparse.cpp
parent63f1c84e38267b2d659ccb041732a8d0c94f51c9 (diff)
downloadsubsurface-e17ad1b0e03f49160d397f84bab8b9251d555d26.tar.gz
Add test for DM5 import
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Diffstat (limited to 'tests/testparse.cpp')
-rw-r--r--tests/testparse.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/testparse.cpp b/tests/testparse.cpp
index 47eb952ef..b614560b5 100644
--- a/tests/testparse.cpp
+++ b/tests/testparse.cpp
@@ -163,6 +163,16 @@ void TestParse::testParseDM4()
SUBSURFACE_TEST_DATA "/dives/TestDiveDM4.xml");
}
+void TestParse::testParseDM5()
+{
+ QCOMPARE(sqlite3_open(SUBSURFACE_TEST_DATA "/dives/TestDiveDM5.db", &_sqlite3_handle), 0);
+ QCOMPARE(parse_dm5_buffer(_sqlite3_handle, 0, 0, 0, &dive_table), 0);
+
+ QCOMPARE(save_dives("./testdm5out.ssrf"), 0);
+ FILE_COMPARE("./testdm5out.ssrf",
+ SUBSURFACE_TEST_DATA "/dives/TestDiveDM5.xml");
+}
+
void TestParse::testParseHUDC()
{
char *params[37];