@Test public void shouldThrowNPE() throws Exception { try { acceptHeaderLocaleProvider.resolveLocale(null); fail("npe should be thrown"); } catch (Exception ex) { } }
public Optional<Locale> resolveLocale(final HttpServletRequest request) { return Optional.fromNullable(request.getLocale()); }
AcceptHeaderLocaleProvider implements LocaleProvider { public Optional<Locale> resolveLocale(final HttpServletRequest request) { return Optional.fromNullable(request.getLocale()); } }
AcceptHeaderLocaleProvider implements LocaleProvider { public Optional<Locale> resolveLocale(final HttpServletRequest request) { return Optional.fromNullable(request.getLocale()); }  }
AcceptHeaderLocaleProvider implements LocaleProvider { public Optional<Locale> resolveLocale(final HttpServletRequest request) { return Optional.fromNullable(request.getLocale()); }  Optional<Locale> resolveLocale(final HttpServletRequest request); }
AcceptHeaderLocaleProvider implements LocaleProvider { public Optional<Locale> resolveLocale(final HttpServletRequest request) { return Optional.fromNullable(request.getLocale()); }  Optional<Locale> resolveLocale(final HttpServletRequest request);  }