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(test): Fix require outside of main goroutine #908

Merged
merged 3 commits into from
Feb 9, 2024
Merged

fix(test): Fix require outside of main goroutine #908

merged 3 commits into from
Feb 9, 2024

Conversation

EduardGomezEscandell
Copy link
Contributor

If a require check fails outside of the main goroutine, it causes a panic.

This test is a common pattern in our projects, so I went looking for it after having golangci-lint warn about it in Ubuntu Pro for WSL.

If a require check fails outside of the main goroutine, it causes a
panic.

This test is a common pattern in our projects, so I went looking for it
after having golangci-lint warn about it in Ubuntu Pro for WSL.
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (17468b3) 87.61% compared to head (aa1b43f) 87.61%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #908   +/-   ##
=======================================
  Coverage   87.61%   87.61%           
=======================================
  Files          75       75           
  Lines        6694     6694           
=======================================
  Hits         5865     5865           
  Misses        492      492           
  Partials      337      337           

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

@EduardGomezEscandell EduardGomezEscandell marked this pull request as ready for review February 9, 2024 10:48
@EduardGomezEscandell EduardGomezEscandell requested a review from a team as a code owner February 9, 2024 10:48
Copy link
Member

@didrocks didrocks left a comment

Choose a reason for hiding this comment

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

Small suggestion on the naming

cmd/adsysd/daemon/daemon_test.go Outdated Show resolved Hide resolved
Copy link
Contributor

@GabrielNagy GabrielNagy left a comment

Choose a reason for hiding this comment

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

Good catch!

@EduardGomezEscandell
Copy link
Contributor Author

Feel free to merge, I think I don't have permissions.

@jibel jibel merged commit c68d2cc into ubuntu:main Feb 9, 2024
4 checks passed
@EduardGomezEscandell EduardGomezEscandell deleted the require-outside-test-goroutine branch February 9, 2024 13:38
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.

5 participants