-
-
Notifications
You must be signed in to change notification settings - Fork 401
Added MILL_TEST_FREE_PORT #4931
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
base: main
Are you sure you want to change the base?
Conversation
RE: There is some failing tests on HEAD right now. I think
Might be related to the PR but im not sure. I will be investigating, |
/** | ||
* Used to store free ports for Mill's tests to use. | ||
*/ | ||
public static final String MILL_TEST_FREE_PORT = "MILL_TEST_FREE_PORT"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a single port or multiple. The comment is a bit vague. If it is multi, that the variable should be MILL_TEST_FREE_PORTS
and we should document here, which separator is used.
var i = 0 | ||
var ports = Set.empty[Int] | ||
for (_ <- 1 to 100) { | ||
if (i == 6) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Magic number 6
! A parameter or a named constant might be better.
} | ||
|
||
streams.err.println( | ||
"Failed to generate enough ports for servers to use. Either there isn't 6 free ports on your computer, or there is a firewall issue. " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Magic number 6
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Magic number
6
.
Fixed but, maybe we don't need to do this at all.
This doesn't satisfy the original issue
|
I misunderstood, I thought that were to be done in a second PR. I will work on this. |
Made in accordance to #3802