From d891661c4ae0eb6856c3a5ebe52687479c5f584f Mon Sep 17 00:00:00 2001 From: Jesse Wilson Date: Fri, 16 Dec 2011 04:57:22 +0000 Subject: [PATCH] Apply locale fix for date type adapter test. Fixes issue 381. --- .../test/java/com/google/gson/DefaultDateTypeAdapterTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gson/src/test/java/com/google/gson/DefaultDateTypeAdapterTest.java b/gson/src/test/java/com/google/gson/DefaultDateTypeAdapterTest.java index 1b94f3d9..966a8c18 100644 --- a/gson/src/test/java/com/google/gson/DefaultDateTypeAdapterTest.java +++ b/gson/src/test/java/com/google/gson/DefaultDateTypeAdapterTest.java @@ -127,7 +127,7 @@ public class DefaultDateTypeAdapterTest extends TestCase { public void testDateSerialization() throws Exception { int dateStyle = DateFormat.LONG; DefaultDateTypeAdapter dateTypeAdapter = new DefaultDateTypeAdapter(dateStyle); - DateFormat formatter = DateFormat.getDateInstance(dateStyle); + DateFormat formatter = DateFormat.getDateInstance(dateStyle, Locale.US); Date currentDate = new Date(); String dateString = dateTypeAdapter.serialize(currentDate, Date.class, null).getAsString();