YARN-2388. Fixed TestTimelineWebServices failure due to HADOOP-10791. Contributed by Zhijie Shen.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1616405 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
8feddc4c84
commit
be6360593b
@ -140,6 +140,8 @@ Release 2.6.0 - UNRELEASED
|
|||||||
YARN-2359. Application hangs when it fails to launch AM container.
|
YARN-2359. Application hangs when it fails to launch AM container.
|
||||||
(Zhihai Xu via kasha)
|
(Zhihai Xu via kasha)
|
||||||
|
|
||||||
|
YARN-2388. Fixed TestTimelineWebServices failure due to HADOOP-10791. (zjshen)
|
||||||
|
|
||||||
Release 2.5.0 - UNRELEASED
|
Release 2.5.0 - UNRELEASED
|
||||||
|
|
||||||
INCOMPATIBLE CHANGES
|
INCOMPATIBLE CHANGES
|
||||||
|
@ -33,6 +33,7 @@
|
|||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import javax.servlet.FilterConfig;
|
import javax.servlet.FilterConfig;
|
||||||
|
import javax.servlet.ServletContext;
|
||||||
import javax.servlet.ServletException;
|
import javax.servlet.ServletException;
|
||||||
import javax.ws.rs.core.MediaType;
|
import javax.ws.rs.core.MediaType;
|
||||||
|
|
||||||
@ -105,6 +106,8 @@ protected void configureServlets() {
|
|||||||
.thenReturn("simple");
|
.thenReturn("simple");
|
||||||
when(filterConfig.getInitParameter(
|
when(filterConfig.getInitParameter(
|
||||||
PseudoAuthenticationHandler.ANONYMOUS_ALLOWED)).thenReturn("true");
|
PseudoAuthenticationHandler.ANONYMOUS_ALLOWED)).thenReturn("true");
|
||||||
|
ServletContext context = mock(ServletContext.class);
|
||||||
|
when(filterConfig.getServletContext()).thenReturn(context);
|
||||||
Enumeration<Object> names = mock(Enumeration.class);
|
Enumeration<Object> names = mock(Enumeration.class);
|
||||||
when(names.hasMoreElements()).thenReturn(true, true, false);
|
when(names.hasMoreElements()).thenReturn(true, true, false);
|
||||||
when(names.nextElement()).thenReturn(
|
when(names.nextElement()).thenReturn(
|
||||||
|
Loading…
Reference in New Issue
Block a user