Polish async support
Added handler argument to the signature of AsyncHandlerInterceptor.afterConcurrentHandlingStarted(..). Renamed AsyncWebUtils to WebAsyncUtils.
This commit is contained in:
@@ -51,7 +51,7 @@ public class WebAsyncManagerTests {
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
this.asyncManager = AsyncWebUtils.getAsyncManager(new MockHttpServletRequest());
|
||||
this.asyncManager = WebAsyncUtils.getAsyncManager(new MockHttpServletRequest());
|
||||
this.asyncManager.setTaskExecutor(new SyncTaskExecutor());
|
||||
|
||||
this.asyncWebRequest = createStrictMock(AsyncWebRequest.class);
|
||||
@@ -142,7 +142,7 @@ public class WebAsyncManagerTests {
|
||||
|
||||
@Test
|
||||
public void startCallableProcessingNullRequest() {
|
||||
WebAsyncManager manager = AsyncWebUtils.getAsyncManager(new MockHttpServletRequest());
|
||||
WebAsyncManager manager = WebAsyncUtils.getAsyncManager(new MockHttpServletRequest());
|
||||
try {
|
||||
manager.startCallableProcessing(new Callable<Object>() {
|
||||
public Object call() throws Exception {
|
||||
|
||||
@@ -33,7 +33,7 @@ import junit.framework.TestCase;
|
||||
import org.springframework.mock.web.MockFilterConfig;
|
||||
import org.springframework.mock.web.MockHttpServletResponse;
|
||||
import org.springframework.mock.web.MockServletContext;
|
||||
import org.springframework.web.context.request.async.AsyncWebUtils;
|
||||
import org.springframework.web.context.request.async.WebAsyncUtils;
|
||||
|
||||
/**
|
||||
* @author Rick Evans
|
||||
@@ -176,9 +176,9 @@ public class CharacterEncodingFilterTests extends TestCase {
|
||||
|
||||
|
||||
private void addAsyncManagerExpectations(HttpServletRequest request) {
|
||||
expect(request.getAttribute(AsyncWebUtils.WEB_ASYNC_MANAGER_ATTRIBUTE)).andReturn(null);
|
||||
expect(request.getAttribute(WebAsyncUtils.WEB_ASYNC_MANAGER_ATTRIBUTE)).andReturn(null);
|
||||
expectLastCall().anyTimes();
|
||||
request.setAttribute(same(AsyncWebUtils.WEB_ASYNC_MANAGER_ATTRIBUTE), notNull());
|
||||
request.setAttribute(same(WebAsyncUtils.WEB_ASYNC_MANAGER_ATTRIBUTE), notNull());
|
||||
expectLastCall().anyTimes();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user