Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 363584

Summary: [Test] Compile errors in help tests due to introduction of servlet 3.0
Product: [Eclipse Project] Platform Reporter: John Arthorne <john.arthorne>
Component: User AssistanceAssignee: platform-ua-inbox <platform-ua-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: cgold, ChrisAustin, kim.moir, sja.eclipse, tjwatson
Version: 4.2   
Target Milestone: 3.8 M4   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
Git style patch
none
Regular style patch none

Description John Arthorne CLA 2011-11-11 08:55:22 EST
There are compile errors in N20111110 due to the new servlet 3.0 work being added to the build. See bug 362724.

help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java : 12 errors :
1. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.getServletContext()
2. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.isAsyncSupported()
3. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.getAsyncContext()
4. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.startAsync(ServletRequest, ServletResponse)
5. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.startAsync()
6. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method HttpServletRequest.logout()
7. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.isAsyncStarted()
8. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method HttpServletRequest.login(String, String)
9. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method ServletRequest.getDispatcherType()
10. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method HttpServletRequest.getPart(String)
11. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method HttpServletRequest.getParts()
12. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletRequest.java
 (at line 33)
public class MockServletRequest implements HttpServletRequest {
The type MockServletRequest must implement the inherited abstract method HttpServletRequest.authenticate(HttpServletResponse)
/help/org/eclipse/ua/tests/help/webapp/MockServletResponse.java : 4 errors :
1. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletResponse.java
 (at line 28)
public class MockServletResponse implements HttpServletResponse {
The type MockServletResponse must implement the inherited abstract method HttpServletResponse.getHeaderNames()
2. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletResponse.java
 (at line 28)
public class MockServletResponse implements HttpServletResponse {
The type MockServletResponse must implement the inherited abstract method HttpServletResponse.getHeader(String)
3. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletResponse.java
 (at line 28)
public class MockServletResponse implements HttpServletResponse {
The type MockServletResponse must implement the inherited abstract method HttpServletResponse.getHeaders(String)
4. ERROR in /help/org/eclipse/ua/tests/help/webapp/MockServletResponse.java
 (at line 28)
public class MockServletResponse implements HttpServletResponse {
The type MockServletResponse must implement the inherited abstract method HttpServletResponse.getStatus()
Comment 1 Thomas Watson CLA 2011-11-11 09:09:49 EST
Simon please look at this ASAP and provide a patch.  We will find someone to commit it.
Comment 2 Simon Archer CLA 2011-11-11 15:20:55 EST
Looking...
Comment 3 Simon Archer CLA 2011-11-11 16:59:48 EST
Created attachment 206885 [details]
Git style patch

Looking at the existing code I simply copied the convention of providing no-op implementations of the missing methods. Clearly this might be inappropriate, but I don't think it is in this case.
Comment 4 Simon Archer CLA 2011-11-14 11:05:59 EST
Created attachment 206958 [details]
Regular style patch
Comment 5 Chris Goldthorpe CLA 2011-11-14 12:08:12 EST
Your patch looks like it pulled in a lot of changes that had nothing to do with org.eclipse.ua.tests. I have added the missing methods myself using quick fix ( none of the methods added to this class will get called when running the tests ).

A fix has been committed with commit message: Bug 363584 - [Test] Compile errors in help tests due to introduction of servlet 3.0
Comment 6 Kim Moir CLA 2011-11-15 10:29:06 EST
Looks like the compile error is fixed in N20111114-2115.  Thanks Simon and Chris.