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

chore: add target to update golden-files for individual tests #1369

Merged
merged 2 commits into from
Feb 28, 2020

Conversation

zmalik
Copy link
Member

@zmalik zmalik commented Feb 27, 2020

Signed-off-by: Zain Malik zmalikshxil@gmail.com

What this PR does / why we need it:
Updating the golden files for tests wasn't documented and for first time contributors to those it can be hard to discover how to do it.

This PR adds a Make target to update golden files, and requires the name of individual test to update only one by one. This is to address concerns to avoid doing a massive update in golden files by error
examples:

make update-golden-TestInitCmd_dry
make update-golden-TestParamsList

Signed-off-by: Zain Malik <zmalikshxil@gmail.com>
Copy link
Member

@porridge porridge left a comment

Choose a reason for hiding this comment

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

😍

test/README.md Outdated Show resolved Hide resolved
Makefile Outdated Show resolved Hide resolved
Copy link
Member

@ANeumann82 ANeumann82 left a comment

Choose a reason for hiding this comment

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

Nice middle ground, I like it.

@zen-dog
Copy link
Contributor

zen-dog commented Feb 28, 2020

Nice middle ground, I like it.

Indeed! I like this!

Signed-off-by: Zain Malik <zmalikshxil@gmail.com>

Co-Authored-By: Marcin Owsiany <mowsiany@D2iQ.com>
@zmalik zmalik merged commit 04941d2 into master Feb 28, 2020
@zmalik zmalik deleted the zain/golden-files-update branch February 28, 2020 11:40
runyontr pushed a commit that referenced this pull request Mar 11, 2020
* chore: add make target to update golden-files for individual tests
* Apply suggestions from code review

Signed-off-by: Zain Malik <zmalikshxil@gmail.com>
Co-Authored-By: Marcin Owsiany <mowsiany@D2iQ.com>
Co-authored-by: Marcin Owsiany <marcin@owsiany.pl>
Signed-off-by: Thomas Runyon <runyontr@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants