From 17526ded58703064dedebdf53669e12f0ab4f43e Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Thu, 23 Apr 2020 23:32:42 +0200 Subject: cleanup: move clearing of device nodes to clear_dive_file_data() It makes no sense to keep the device nodes if all the other data is cleared. Let's do this automatically and not explicitly. This ensures that the function is also called on mobile. Currently it was only called on desktop. Weirdly, the parser-tests were expecting that the device nodes were not reset by clear_dive_file_data() and therefore divecomputers were accumulating in the test results. Thus, the additional computers had to be removed from the expected test results. Signed-off-by: Berthold Stoeger --- tests/testparse.cpp | 5 ----- 1 file changed, 5 deletions(-) (limited to 'tests') diff --git a/tests/testparse.cpp b/tests/testparse.cpp index 06c110acb..39e8a605d 100644 --- a/tests/testparse.cpp +++ b/tests/testparse.cpp @@ -286,11 +286,6 @@ void TestParse::testParseDLD() fprintf(stderr, "number of dives from DLD: %d \n", dive_table.nr); // Compare output - /* - * DC is not cleared from previous tests with the - * clear_dive_file_data(), so we do have an additional DC nick - * name field on the log. - */ QCOMPARE(save_dives("./testdldout.ssrf"), 0); FILE_COMPARE("./testdldout.ssrf", SUBSURFACE_TEST_DATA "/dives/TestDiveDivelogsDE.xml") -- cgit v1.2.3-70-g09d2