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

Update exhaustivestruct #1472

Merged
merged 2 commits into from Oct 26, 2020
Merged

Update exhaustivestruct #1472

merged 2 commits into from Oct 26, 2020

Conversation

mbilski
Copy link
Contributor

@mbilski mbilski commented Oct 26, 2020

fixes:

  • ignore private fields
  • report multiple missing fields at once

Copy link
Member

@bombsimon bombsimon left a comment

Choose a reason for hiding this comment

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

Generally looks good but how do you feel about tests? Of course the heavy lifting and majority of testing should be a part of the linter but I think it's good to cover at least one of each pass in this repo too. The reason being that a too big change to the linter hidden behind a change to only go.mod could have unexpected affect to the end user. By always ensuring the testdata adds or removes passes it's easier to see how big the change is.

Wdyt? Should we add tests for the changes you did such as ignoring private fields or do you think the single pass in the current testdata is enough?

@mbilski
Copy link
Contributor Author

mbilski commented Oct 26, 2020

Generally looks good but how do you feel about tests? Of course the heavy lifting and majority of testing should be a part of the linter but I think it's good to cover at least one of each pass in this repo too. The reason being that a too big change to the linter hidden behind a change to only go.mod could have unexpected affect to the end user. By always ensuring the testdata adds or removes passes it's easier to see how big the change is.

Wdyt? Should we add tests for the changes you did such as ignoring private fields or do you think the single pass in the current testdata is enough?

makes sense, I'll add some tests

Copy link
Member

@bombsimon bombsimon left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM!

@bombsimon bombsimon merged commit 55e35d2 into golangci:master Oct 26, 2020
@ldez ldez added the linter: update version Update version of linter label Dec 7, 2020
@ldez ldez added this to the v1.32 milestone Mar 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
linter: update version Update version of linter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants