-
Notifications
You must be signed in to change notification settings - Fork 55
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
Stackdriver integration tests #140
Stackdriver integration tests #140
Conversation
eak, also, i'm unsure whether the encrypted file will decrypt post merge. |
ok, it seems like i may have to add the encrypted key via @adriancole let me know if you are OK w/ me adding the encrypted key directly on |
...ackdriver/src/test/java/zipkin2/reporter/stackdriver/AsyncReporterStackdriverSenderTest.java
Outdated
Show resolved
Hide resolved
I have a change in brave I've neglected for a long time so look at this closer after that. thanks for the help! |
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.
Looks good from my end; a couple of optional comments [on comments, as it happens].
sender-stackdriver/src/test/java/zipkin2/reporter/stackdriver/ITStackdriverSender.java
Outdated
Show resolved
Hide resolved
sender-stackdriver/src/test/java/zipkin2/reporter/stackdriver/ITStackdriverSender.java
Outdated
Show resolved
Hide resolved
public void setUp() { | ||
server.getServiceRegistry().addService(traceService); | ||
public void setUp() throws IOException { | ||
// Application Default credential is configured using the GOOGLE_APPLICATION_CREDENTIALS env var |
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.
Maybe or gcloud SDK when run locally.
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.
in the context of this test, i think the env var is better way, the other ways should be documented in the linked page (but also, not recommended).
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.
I'd prefer to see an assumeThat
here which will ignore the test vs break the build, when remote stuff is not around. That way you can craft a better error. PS I think the build is broke not sure intended or not.
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.
TIL :D updated to use assumeThatCode
since GoogleCredentials.getApplicationDefault
throws an exception that we need to catch.
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.
looks good. one note besides looking into why this doesn't run in travis. If it is a permissions concern, odd, but let me know. maybe it is one of those things where you need to merge first. At any rate, let's use assume.. in order to keep it green.
public void setUp() { | ||
server.getServiceRegistry().addService(traceService); | ||
public void setUp() throws IOException { | ||
// Application Default credential is configured using the GOOGLE_APPLICATION_CREDENTIALS env var |
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.
I'd prefer to see an assumeThat
here which will ignore the test vs break the build, when remote stuff is not around. That way you can craft a better error. PS I think the build is broke not sure intended or not.
…refreshAccessToken failed.
something still seems busted.. |
it looks like the assumption was determined not met
but it's still a failure rather than a skip. |
if me, I'd check the state it needs instead as the error message isn't 100% clear anyway. there's a slight drift risk, but then if there was, we'd have to reconfig the job |
even if i tried a simple |
ok i think i found the issue... |
…ailing tests. during tear down, only close reporter if reporter is not null, otherwise, tearDown() will cause test failures.
looks like you did. good detective work again @saturnism. Thanks for all the work. |
#130
ITStackdriverSender
test toAsyncReporterStackdriverSenderTest.java
ITStackdriverSender
to test against a service accountGOOGLE_APPLICATION_CREDENTIALS
env var