aboutsummaryrefslogtreecommitdiff
path: root/test/org/traccar
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-10-22 16:59:48 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-10-22 16:59:48 +1300
commit1f57b64574778a3f26e0f23c7878c8495e6c5f89 (patch)
tree8b51081c2b175e40edd7b744afa3e4a9d6902a45 /test/org/traccar
parentccefc3b345e0943bedf49ce515106b1f210971f1 (diff)
downloadtrackermap-server-1f57b64574778a3f26e0f23c7878c8495e6c5f89.tar.gz
trackermap-server-1f57b64574778a3f26e0f23c7878c8495e6c5f89.tar.bz2
trackermap-server-1f57b64574778a3f26e0f23c7878c8495e6c5f89.zip
Fix time formatting issue
Diffstat (limited to 'test/org/traccar')
-rw-r--r--test/org/traccar/ProtocolDecoderTest.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/org/traccar/ProtocolDecoderTest.java b/test/org/traccar/ProtocolDecoderTest.java
index 8aec40c77..f58de880a 100644
--- a/test/org/traccar/ProtocolDecoderTest.java
+++ b/test/org/traccar/ProtocolDecoderTest.java
@@ -18,6 +18,7 @@ import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;
+import java.util.TimeZone;
public class ProtocolDecoderTest {
@@ -136,6 +137,7 @@ public class ProtocolDecoderTest {
if (expected.getFixTime() != null) {
DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
+ dateFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
Assert.assertEquals("time",
dateFormat.format(expected.getFixTime()), dateFormat.format(position.getFixTime()));
}