aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src
diff options
context:
space:
mode:
Diffstat (limited to 'tests/src')
-rw-r--r--tests/src/cgeo/geocaching/export/ExportTest.java3
-rw-r--r--tests/src/cgeo/geocaching/files/GPXParserTest.java4
2 files changed, 4 insertions, 3 deletions
diff --git a/tests/src/cgeo/geocaching/export/ExportTest.java b/tests/src/cgeo/geocaching/export/ExportTest.java
index aeab90e..a9fceec 100644
--- a/tests/src/cgeo/geocaching/export/ExportTest.java
+++ b/tests/src/cgeo/geocaching/export/ExportTest.java
@@ -13,6 +13,7 @@ import cgeo.geocaching.utils.FileUtils;
import java.io.File;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.List;
import java.util.concurrent.ExecutionException;
@@ -32,8 +33,8 @@ public class ExportTest extends CGeoTestCase {
cache.setGeocode("GCX1234");
cache.setCoords(new Geopoint("N 49 44.000 E 8 37.000"));
final LogEntry log = new LogEntry(1353244820000L, LogType.FOUND_IT, "Smile: \ud83d\ude0a");
- cache.getLogs().add(log);
DataStore.saveCache(cache, LoadFlags.SAVE_ALL);
+ DataStore.saveLogsWithoutTransaction(cache.getGeocode(), Collections.singletonList(log));
ArrayList<Geocache> exportList = new ArrayList<Geocache>();
exportList.add(cache);
GpxExportTester gpxExport = new GpxExportTester();
diff --git a/tests/src/cgeo/geocaching/files/GPXParserTest.java b/tests/src/cgeo/geocaching/files/GPXParserTest.java
index 4cd0b6f..e1f3417 100644
--- a/tests/src/cgeo/geocaching/files/GPXParserTest.java
+++ b/tests/src/cgeo/geocaching/files/GPXParserTest.java
@@ -265,8 +265,8 @@ public class GPXParserTest extends AbstractResourceInstrumentationTestCase {
final Geocache minimalCache = DataStore.loadCache(geocode, EnumSet.of(LoadFlag.LOAD_DB_MINIMAL));
// now check that we load lazy members on demand
- assertThat(minimalCache.getAttributes().isEmpty()).isFalse();
- assertThat(minimalCache.getLogs().isEmpty()).isFalse();
+ assertThat(minimalCache.getAttributes()).isNotEmpty();
+ assertThat(minimalCache.getLogs()).isNotEmpty();
removeCacheCompletely(geocode);
}