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

Add Addr() method to server #193

Merged
merged 1 commit into from
Apr 4, 2024

Conversation

fearful-symmetry
Copy link
Contributor

What does this PR do?

This exposes the net.Addr interfaced used by the API server. This is done to help testing, since most of our tests are designed to fetch the nearest open port, so it's helpful to just have a method where we can return the addr and see what port we got allocated in the underlying listener.

Why is it important?

This aids in writing tests.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have added tests that prove my fix is effective or that my feature works

@fearful-symmetry fearful-symmetry added the Team:Elastic-Agent Label for the Agent team label Apr 4, 2024
@fearful-symmetry fearful-symmetry self-assigned this Apr 4, 2024
@fearful-symmetry fearful-symmetry requested a review from a team as a code owner April 4, 2024 15:47
@fearful-symmetry fearful-symmetry requested review from faec and leehinman and removed request for a team April 4, 2024 15:47
@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

cc @fearful-symmetry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Elastic-Agent Label for the Agent team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants