@Test public void testLocale() { String value = LOCALE_CUSTOM.toString(); Cookie cookie = new Cookie(DEFAULT_COOKIE_NAME, value); when(request.getCookies()).thenReturn(new Cookie[]{cookie}); Locale locale = resolver.resolveLocale(request); assertThat(locale).isNotNull(); assertThat(locale).isEqualTo(LOCALE_CUSTOM); List<Event> events = recorder.play(); assertThat(events).isEmpty(); }
@Override public Locale resolveLocale(HttpServletRequest request) { parseAngularCookieIfNecessary(request); return (Locale) request.getAttribute(LOCALE_REQUEST_ATTRIBUTE_NAME); }
AngularCookieLocaleResolver extends CookieLocaleResolver { @Override public Locale resolveLocale(HttpServletRequest request) { parseAngularCookieIfNecessary(request); return (Locale) request.getAttribute(LOCALE_REQUEST_ATTRIBUTE_NAME); } }
AngularCookieLocaleResolver extends CookieLocaleResolver { @Override public Locale resolveLocale(HttpServletRequest request) { parseAngularCookieIfNecessary(request); return (Locale) request.getAttribute(LOCALE_REQUEST_ATTRIBUTE_NAME); }  }
AngularCookieLocaleResolver extends CookieLocaleResolver { @Override public Locale resolveLocale(HttpServletRequest request) { parseAngularCookieIfNecessary(request); return (Locale) request.getAttribute(LOCALE_REQUEST_ATTRIBUTE_NAME); }  @Override Locale resolveLocale(HttpServletRequest request); @Override LocaleContext resolveLocaleContext(final HttpServletRequest request); @Override void addCookie(HttpServletResponse response, String cookieValue); }
AngularCookieLocaleResolver extends CookieLocaleResolver { @Override public Locale resolveLocale(HttpServletRequest request) { parseAngularCookieIfNecessary(request); return (Locale) request.getAttribute(LOCALE_REQUEST_ATTRIBUTE_NAME); }  @Override Locale resolveLocale(HttpServletRequest request); @Override LocaleContext resolveLocaleContext(final HttpServletRequest request); @Override void addCookie(HttpServletResponse response, String cookieValue); static final String QUOTE; }