-
Notifications
You must be signed in to change notification settings - Fork 7
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
Test suite: Only run the c1,c2
hostname test in CI
#29
Test suite: Only run the c1,c2
hostname test in CI
#29
Conversation
b069bdb
to
7e88517
Compare
3fcb9fe
to
7c8d28c
Compare
7c8d28c
to
b7f09cb
Compare
Alright, @kleinhenz this is now ready for review. @jbphyswx This should make it easier for people to run the |
test/script.jl
Outdated
if hosts != ["c1", "c1", "c2", "c2"] | ||
msg = "Test failed: observed_hosts=$(hosts) does not match expected_hosts=[c1, c1, c2, c2]" | ||
error(msg) | ||
const is_ci = parse(Bool, strip(get(ENV, "CI", "false"))) |
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 actually present in our CI since we are running inside the docker compose cluster?
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.
Ah, that's a really good point. No, I don't think it is.
Hmmm. I'll have to figure something else out.
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.
Alright, I have a different approach now.
If the environment variable is not set (e.g. if you are inside of our Docker Compose cluster), we default to is_ci = true
.
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.
So if you look at the CI logs on this PR (e.g. this CI log), you'll see the following message:
[ Info: This is CI, so we will perform the hostname test
This indicates that the test is being run on our CI, as desired.
021e827
to
21e033c
Compare
8233707
to
b3ec9a0
Compare
Depends on:
@assert
s to errors, and change bareusing Foo
tousing Foo: name, anothername, ...
#28