Skip to content
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

Fix bug of E2E test case #3899

Closed
wants to merge 1 commit into from

Conversation

ywk253100
Copy link
Contributor

@ywk253100 ywk253100 commented Jun 25, 2021

  1. The variable "stdoutBuf" is assigned to both "installPluginCmd.Stdout" and "installPluginCmd.Stderr", this causes 'if !strings.Contains(stderrBuf.String(), "Duplicate value")' takes no effect as the "stderrBuf.String()" is always empty
  2. Print the stdout and stderr for easy debugging

Signed-off-by: Wenkai Yin(尹文开) yinw@vmware.com

Thank you for contributing to Velero!

Please add a summary of your change

Does your change fix a particular issue?

Fixes #(issue)

Please indicate you've done the following:

1. The variable "stdoutBuf" is assigned to both "installPluginCmd.Stdout" and "installPluginCmd.Stderr", this causes 'if !strings.Contains(stderrBuf.String(), "Duplicate value")' takes no effect as the "stderrBuf.String()" is always empty
2. Print the stdout and stderr for easy debugging

Signed-off-by: Wenkai Yin(尹文开) <yinw@vmware.com>
@ywk253100 ywk253100 added the kind/changelog-not-required PR does not require a user changelog. Often for docs, website, or build changes label Jun 25, 2021
@jenting jenting requested review from dsu-igeek and zubron June 25, 2021 10:40
if err != nil {
fmt.Println(stdout)
fmt.Println(stderr)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is trivial but for consistency, how about handle the stdout/stderr following this convention?

https://github.com/reasonerjt/velero/blob/9ffffda11e90241b6b74e9d81b578e631b435a99/pkg/controller/pod_volume_restore_controller.go#L378

@carlisia carlisia removed their request for review June 28, 2021 13:28
@ywk253100
Copy link
Contributor Author

Closing this PR as the fix is included in #3912

@ywk253100 ywk253100 closed this Jun 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
has-e2e-tests kind/changelog-not-required PR does not require a user changelog. Often for docs, website, or build changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants