You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@juneau.apache.org by st...@apache.org on 2019/08/06 10:22:38 UTC

[juneau] branch locale-root created (now f8c25f1)

This is an automated email from the ASF dual-hosted git repository.

stain pushed a change to branch locale-root
in repository https://gitbox.apache.org/repos/asf/juneau.git.


      at f8c25f1  Use Locale.ROOT during test

This branch includes the following new commits:

     new f8c25f1  Use Locale.ROOT during test

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[juneau] 01/01: Use Locale.ROOT during test

Posted by st...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

stain pushed a commit to branch locale-root
in repository https://gitbox.apache.org/repos/asf/juneau.git

commit f8c25f1180e964cb7b18c2c5a0dad4b5b23cbd47
Author: Stian Soiland-Reyes <st...@apache.org>
AuthorDate: Tue Aug 6 11:22:07 2019 +0100

    Use Locale.ROOT during test
---
 .../test/java/org/apache/juneau/transforms/LocalizedDatesTest.java | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/juneau-core/juneau-core-utest/src/test/java/org/apache/juneau/transforms/LocalizedDatesTest.java b/juneau-core/juneau-core-utest/src/test/java/org/apache/juneau/transforms/LocalizedDatesTest.java
index 5185e40..ee217f7 100644
--- a/juneau-core/juneau-core-utest/src/test/java/org/apache/juneau/transforms/LocalizedDatesTest.java
+++ b/juneau-core/juneau-core-utest/src/test/java/org/apache/juneau/transforms/LocalizedDatesTest.java
@@ -35,16 +35,21 @@ public class LocalizedDatesTest {
 	}
 
 	private static TimeZone prevTimeZone;
+	private static Locale prevLocale;
 
 	@BeforeClass
 	public static void before() {
 		prevTimeZone = TimeZone.getDefault();
 		TimeZone.setDefault(TimeZone.getTimeZone("GMT"));
+		prevLocale = Locale.getDefault();
+		Locale.setDefault(Locale.ROOT);
+
 	}
 
 	@AfterClass
 	public static void after() {
 		TimeZone.setDefault(prevTimeZone);
+		Locale.setDefault(prevLocale);
 	}
 
 
@@ -659,4 +664,4 @@ public class LocalizedDatesTest {
 			actual2 = actual2.replaceAll("\\([^\\)]+\\) ", "").replaceAll(" \\([^\\)]+\\)", "");  // Fix Windows-specific formatting difference
 		assertEquals(expected, actual2);
 	}
-}
\ No newline at end of file
+}