Skip to content

Comments

[Tests] Fix flaky test ConnectionTimeoutTest#15865

Merged
lhotari merged 1 commit intoapache:masterfrom
lhotari:lh-fix-ConnectionTimeoutTest
May 31, 2022
Merged

[Tests] Fix flaky test ConnectionTimeoutTest#15865
lhotari merged 1 commit intoapache:masterfrom
lhotari:lh-fix-ConnectionTimeoutTest

Conversation

@lhotari
Copy link
Member

@lhotari lhotari commented May 31, 2022

Motivation

  • the original test assumed that 192.0.2.1 is a "black hole" and can be used for testing
    connection timeouts.
    This is an assumption which doesn't hold when a firewall blocks such connections. This causes the test to be flaky.

Modifications

  • Refactor ConnectionTimeoutTest
    • create a dummy TCP/IP server and fill the backlog so that it won't respond and becomes
      a "black hole"

- the original test assumed that 192.0.2.1 is a "black hole" and can be used for testing
  connection timeouts.
  This is an assumption which doesn't hold when a firewall blocks such connections.

- create a dummy TCP/IP server and fill the backlog so that it won't respond and becomes
  a "black hole"
@lhotari lhotari added type/flaky-tests doc-not-needed Your PR changes do not impact docs labels May 31, 2022
@lhotari lhotari merged commit bc272fa into apache:master May 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-not-needed Your PR changes do not impact docs type/flaky-tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants