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

testifylint: enable and fix go-require rule #8236

Closed

Conversation

mmorel-35
Copy link
Contributor

@mmorel-35 mmorel-35 commented Sep 21, 2024

Thank you for contributing to Velero!

Please add a summary of your change

Enable and fixes go-require rule of testifylint linter.

Also update golangci-lint version

Does your change fix a particular issue?

Fixes #(issue)

Please indicate you've done the following:

  • Accepted the DCO. Commits without the DCO will delay acceptance.
  • Created a changelog file or added /kind changelog-not-required as a comment on this pull request.
  • Updated the corresponding documentation in site/content/docs/main.

@mmorel-35
Copy link
Contributor Author

/kind changelog-not-required

@github-actions github-actions bot added the kind/changelog-not-required PR does not require a user changelog. Often for docs, website, or build changes label Sep 21, 2024
Copy link

codecov bot commented Sep 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 59.15%. Comparing base (0b74a73) to head (4880274).
Report is 11 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #8236   +/-   ##
=======================================
  Coverage   59.15%   59.15%           
=======================================
  Files         367      367           
  Lines       30777    30777           
=======================================
  Hits        18206    18206           
  Misses      11113    11113           
  Partials     1458     1458           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@blackpiglet
Copy link
Contributor

https://github.com/Antonboom/testifylint?tab=readme-ov-file#go-require

According to the document, it seems replacing the require with assert in the goroutine of test cases is not a good practice.

@mmorel-35 mmorel-35 closed this Sep 25, 2024
@mmorel-35 mmorel-35 deleted the testifylint/go-require branch September 25, 2024 18:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
has-unit-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.

2 participants