forked from upstream-mirrors/OpenTracks
Be more explicit in testing the XML output of GpxTrackWriter.
Instead of producing the comparison strings in the tester just as they are produced in the tested code, use string literals, thus actually testing that the formatting code is working as expected.
This commit is contained in:
@@ -37,10 +37,10 @@ import java.util.TimeZone;
|
||||
*/
|
||||
public class GpxTrackWriter implements TrackFormatWriter {
|
||||
|
||||
static final int LATLONG_FORMAT = Location.FORMAT_DEGREES;
|
||||
static final DecimalFormat ELEVATION_FORMATTER =
|
||||
private static final int LATLONG_FORMAT = Location.FORMAT_DEGREES;
|
||||
private static final DecimalFormat ELEVATION_FORMATTER =
|
||||
new DecimalFormat("#.#");
|
||||
static final SimpleDateFormat TIMESTAMP_FORMATTER =
|
||||
private static final SimpleDateFormat TIMESTAMP_FORMATTER =
|
||||
new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'");
|
||||
static {
|
||||
TIMESTAMP_FORMATTER.setTimeZone(TimeZone.getTimeZone("UTC"));
|
||||
|
||||
Reference in New Issue
Block a user