Details
-
Bug
-
Resolution: Done
-
Optional
-
None
-
None
-
None
Description
testCloseReason has a test-order dependency and fails when run after some other tests even when there's no bug in the code.
More specifically, testCloseReason requires that the AnnotatedClientEndpoint’s MESSAGE field not contain “CLOSED”. If a test (e.g., AnnotatedEndpointTest.testErrorHandling) that sets the AnnotatedClientEndpoint’s MESSAGE field to “CLOSED” is run before testCloseReason, then testCloseReason will fail.
This test can be fixed by resetting the AnnotatedClientEndpoint’s MESSAGE field, as shown in the following pull request.
https://github.com/undertow-io/undertow/pull/684
Note that resetting the AnnotatedClientEndpoint’s MESSAGE field is already done in some of the tests in AnnotatedEndpointTest (e.g., testIdleTimeout, testAnnotatedClientEndpoint).