From 039ed169f5d5a4af9f538f37c8870a0c45b383d3 Mon Sep 17 00:00:00 2001 From: David Gilbert Date: Fri, 23 Feb 2018 06:08:33 +0100 Subject: [PATCH] Backport f19cea1ef6daccda17b9999264481c5b517861d8. --- .../data/time/TimeSeriesCollectionTest.java | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/src/test/java/org/jfree/data/time/TimeSeriesCollectionTest.java b/src/test/java/org/jfree/data/time/TimeSeriesCollectionTest.java index 5b1dea957..2e76a59a2 100644 --- a/src/test/java/org/jfree/data/time/TimeSeriesCollectionTest.java +++ b/src/test/java/org/jfree/data/time/TimeSeriesCollectionTest.java @@ -32,14 +32,6 @@ * Original Author: David Gilbert (for Object Refinery Limited); * Contributor(s): -; * - * Changes - * ------- - * 01-May-2003 : Version 1 (DG); - * 04-Dec-2003 : Added a test for the getSurroundingItems() method (DG); - * 08-May-2007 : Added testIndexOf() method (DG); - * 18-May-2009 : Added testFindDomainBounds() (DG); - * 08-Jan-2012 : Added testBug3445507() (DG); - * */ package org.jfree.data.time; @@ -58,7 +50,6 @@ import java.util.Locale; import java.util.TimeZone; import org.jfree.chart.TestUtils; - import org.jfree.data.Range; import org.jfree.data.general.DatasetUtils; import org.junit.jupiter.api.Test; @@ -309,6 +300,10 @@ public void testIndexOf() { */ @Test public void testFindDomainBounds() { + // store the current time zone + TimeZone saved = TimeZone.getDefault(); + TimeZone.setDefault(TimeZone.getTimeZone("Europe/Paris")); + TimeSeriesCollection dataset = new TimeSeriesCollection(); List visibleSeriesKeys = new ArrayList<>(); Range r = DatasetUtils.findDomainBounds(dataset, visibleSeriesKeys, @@ -321,10 +316,6 @@ public void testFindDomainBounds() { r = DatasetUtils.findDomainBounds(dataset, visibleSeriesKeys, true); assertNull(r); - // store the current time zone - TimeZone saved = TimeZone.getDefault(); - TimeZone.setDefault(TimeZone.getTimeZone("Europe/Paris")); - s1.add(new Year(2008), 8.0); r = DatasetUtils.findDomainBounds(dataset, visibleSeriesKeys, true); assertEquals(1199142000000.0, r.getLowerBound(), EPSILON);