### Question:
SentinelZuulErrorFilter extends ZuulFilter { @Override public boolean shouldFilter() { RequestContext ctx = RequestContext.getCurrentContext(); return ctx.getThrowable() != null; } SentinelZuulErrorFilter();  SentinelZuulErrorFilter(int order); @Override String filterType(); @Override boolean shouldFilter(); @Override int filterOrder(); @Override Object run();  }### Answer:
@Test public void testShouldFilter() { SentinelZuulErrorFilter sentinelZuulErrorFilter = new SentinelZuulErrorFilter(); RequestContext ctx = RequestContext.getCurrentContext(); ctx.setThrowable(new RuntimeException()); Assert.assertTrue(sentinelZuulErrorFilter.shouldFilter()); }