Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

actix-test: allow the configuration of the TestServer address #3351

Merged
merged 5 commits into from
Jun 9, 2024

Conversation

mpalmer
Copy link
Contributor

@mpalmer mpalmer commented May 5, 2024

PR Type

Feature

PR Checklist

  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.
  • A changelog entry has been made for the appropriate packages.
  • Format code with the latest stable rustfmt.
  • (Team) Label with affected crates and semver status.

Overview

This is useful if you're running (say) Selenium tests against a running TestServer, and the Selenium workers are Docker containers elsewhere in the network. Not a particularly common use case, perhaps, but one that I can attest happens every now and then.

This is useful if you're running (say) Selenium tests against a running TestServer, and the Selenium workers are Docker containers elsewhere in the network.
Not a *particularly* common use case, perhaps, but one that I can attest happens every now and then.
@mpalmer mpalmer force-pushed the testserver-listen-address branch from dbd04c3 to 0afdb26 Compare May 5, 2024 23:59
@mpalmer
Copy link
Contributor Author

mpalmer commented May 6, 2024

CI failures appear to be the TlsConnectorService issues that are being addressed in #3350.

@robjtede robjtede added B-semver-minor A-test-server project: test-server labels Jun 9, 2024
@robjtede robjtede enabled auto-merge June 9, 2024 02:52
@robjtede
Copy link
Member

robjtede commented Jun 9, 2024

thanks for the addition 👍🏻

looks like it needs a quick look at the new test failure

@mpalmer
Copy link
Contributor Author

mpalmer commented Jun 9, 2024

Those test failures are weird -- there's no immediately-obvious relationship to my changes. However, since I can't see any recent changes on master that could be to blame, I'll roll up my sleeves and dig in, I guess.

@mpalmer
Copy link
Contributor Author

mpalmer commented Jun 9, 2024

After some rummaging around, I'm fairly confident my changes are at fault, if only because the three failing tests are the ones that are calling actix_test::start, while the other tests are spawning a testing server using other mechanisms. Complicating the problem is that I can't repro the test failures locally, but I'll figure that out one way or another.

auto-merge was automatically disabled June 9, 2024 08:33

Head branch was pushed to by a user without write access

@mpalmer mpalmer force-pushed the testserver-listen-address branch from 5bac6da to 4712250 Compare June 9, 2024 10:10
@mpalmer
Copy link
Contributor Author

mpalmer commented Jun 9, 2024

Test suite passes now. The problem appears to be that, for some mysterious reason, an IPv6 address in the actix-test-constructed URL is being passed in the resolver library, which proceeds to lose its mind. But only in CI -- it works fine for me locally, even when I hard-code an IPv6 listen address. 🤷

@robjtede
Copy link
Member

robjtede commented Jun 9, 2024

The CI runners, on their VMs, probably have some crazy IPv6 things going on.

I think the quick fix is to use 127.0.0.1 as the default instead of localhost.

@robjtede
Copy link
Member

robjtede commented Jun 9, 2024

Ahh I see that's actually what you did. Sorry I was on mobile earlier and didn't check the newest commit.

@robjtede robjtede added this pull request to the merge queue Jun 9, 2024
Merged via the queue into actix:master with commit 758ae1d Jun 9, 2024
13 checks passed
@mpalmer mpalmer deleted the testserver-listen-address branch June 10, 2024 22:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants