faces
faces copied to clipboard
old-tck: applicationSubscribeToEventNPETest contains an error - description of test does not match what the test is doing
https://github.com/jakartaee/faces/blob/master/tck/old-tck/source/src/com/sun/ts/tests/jsf/api/jakarta_faces/application/application/TestServlet.java#L2304
The test documents the following: Running==> application.subscribeToEvent(Class, null, null)
The test performs the following: new Object[] { TCKSystemEvent.class, srcClass, null }, out);
This looks to just be a copy-and-paste error from the test above.
The proposed solution is just to do the following: new Object[] { TCKSystemEvent.class, null, null }, out);
However, I think we should discuss if there is any value in this test at all since null
is allowed for a sourceClass
and an NPE would be thrown just like the test before this one since the listener
is null: https://jakarta.ee/specifications/faces/4.0/apidocs/jakarta/faces/application/application#unsubscribeFromEvent(java.lang.Class,jakarta.faces.event.SystemEventListener)
Merged changes to the 4.1 branch.