-
Notifications
You must be signed in to change notification settings - Fork 77
Add integration test for resourcedetector which read from VM metadata server #856
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 integration test for resourcedetector which read from VM metadata server #856
Conversation
760f35c to
6c7c0a2
Compare
8d45892 to
2b39a1f
Compare
2b39a1f to
6199718
Compare
6199718 to
258933b
Compare
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.
LGTM! Left a couple comments but feel free to merge whenever
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.
We may need to add the license here at the top. Also may be worth adding a comment on what this is used for.
integration_test/ops_agent_test.go
Outdated
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.
[super nit] We should pull this out to a separate local method like runResourceDetectorCli and call it so the test code is more readable and just asserts the test data is accurate.
258933b to
e718a05
Compare
e718a05 to
6a72b8d
Compare
6a72b8d to
15ddeea
Compare
d17a78d to
ae1d42e
Compare
ae1d42e to
1d7d71b
Compare
Description
We have added
resourcedetectorto read from GCE VM metadata server which is used by components such as the Prometheus receivers.This PR added integration test for the
resourcedetector:integration_test/cmd/run_resource_detector/run_resource_detector.goto call the package directly and print the results in JSON to stdout.run_resource_detector.goresolve the dependency of theresourcedetectorpackage locally, we upload the source code of the package as well as go.sum and go.mod.Related issue
b/246615284
How has this been tested?
Checklist: