-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[Docker Log driver] Expand testing, add mocking tooling #14828
[Docker Log driver] Expand testing, add mocking tooling #14828
Conversation
555480c
to
da26d09
Compare
Only some nit picks, LGTM! |
assert.Equal(t, event.Fields["message"], logString) | ||
} | ||
|
||
func setupTestClient(t *testing.T, logString string) (*pipelinemock.MockPipelineConnector, func()) { |
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.
nit; the function name does not match the return type. Where do we create and publish the event?
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, cleaned this up and adding some comments that hopefully clarify this.
Add more integration tests and a mock framework
This adds a 'main' integration test for the client handler and log reader, as well as a set of tools for mocking the publisher pipeline. A few things have shifted around in the client/pipeline managers in order to make testing easier.