mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-09-23 22:19:13 +00:00
fixing time zone in DateFormat for test so that there is no dependency on the executing computer's time zone setting
This commit is contained in:
+2
@@ -7,6 +7,7 @@ import java.net.MalformedURLException;
|
||||
import java.net.URISyntaxException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.List;
|
||||
import java.util.TimeZone;
|
||||
|
||||
import com.sap.sailing.domain.base.impl.MillisecondsTimePoint;
|
||||
import com.sap.sailing.domain.common.ManeuverType;
|
||||
@@ -24,6 +25,7 @@ public abstract class AbstractManeuverDetectionTestCase extends OnlineTracTracBa
|
||||
public AbstractManeuverDetectionTestCase() throws MalformedURLException, URISyntaxException {
|
||||
super();
|
||||
dateFormat = new SimpleDateFormat("MM/dd/yyyy-HH:mm:ss");
|
||||
dateFormat.setTimeZone(TimeZone.getTimeZone("GMT+2")); // will result in CEST
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
-2
@@ -6,7 +6,6 @@ import java.io.IOException;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URISyntaxException;
|
||||
import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.GregorianCalendar;
|
||||
@@ -44,7 +43,6 @@ public class ManeuverAnalysis505Test extends AbstractManeuverDetectionTestCase {
|
||||
getTrackedRace().recordWind(
|
||||
new WindImpl(/* position */null, MillisecondsTimePoint.now(), new KnotSpeedWithBearingImpl(12,
|
||||
new DegreeBearingImpl(65))), new WindSourceImpl(WindSourceType.WEB));
|
||||
dateFormat = new SimpleDateFormat("MM/dd/yyyy-HH:mm:ss");
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user