Uploaded image for project: 'Undertow'
  1. Undertow
  2. UNDERTOW-1435

Fixing flaky test AnnotatedEndpointTest.testCloseReason

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Optional
    • 2.0.17.Final
    • 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).

      Attachments

        Activity

          People

            sdouglas1@redhat.com Stuart Douglas
            ordtesters ORD Testers (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: