rave-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ja...@apache.org
Subject svn commit: r1231653 - /incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java
Date Sun, 15 Jan 2012 11:25:31 GMT
Author: jasha
Date: Sun Jan 15 11:25:30 2012
New Revision: 1231653

URL: http://svn.apache.org/viewvc?rev=1231653&view=rev
Log:
RAVE-299 set default Locale explicitly to Locale.US to pass unit test in case the system locale
is dutch (or in the future any other non-english language we support)

Modified:
    incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java

Modified: incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java
URL: http://svn.apache.org/viewvc/incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java?rev=1231653&r1=1231652&r2=1231653&view=diff
==============================================================================
--- incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java
(original)
+++ incubator/rave/trunk/rave-components/rave-web/src/test/java/org/apache/rave/portal/web/controller/MessageBundleControllerTest.java
Sun Jan 15 11:25:30 2012
@@ -23,8 +23,6 @@ import org.junit.Before;
 import org.junit.Test;
 import org.springframework.mock.web.MockHttpServletRequest;
 import org.springframework.mock.web.MockHttpServletResponse;
-import org.springframework.ui.ExtendedModelMap;
-import org.springframework.ui.Model;
 
 import java.util.Locale;
 
@@ -45,6 +43,7 @@ public class MessageBundleControllerTest
 
     @Test
     public void getClientMessages_defaultLocale() {
+        Locale.setDefault(Locale.US);
         final String EXPECTED_JS = buildExpectedJavaScript("mother", "father", "text with
\\\"quotes\\\"");
         assertThat(messageBundleController.getClientMessages(request, response), is(EXPECTED_JS));
         assertThat(response.getContentType(), is("application/javascript"));



Mime
View raw message