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

test(i): Handle error in test setup, don't return nil #3403

Merged

Conversation

shahzadlone
Copy link
Member

Relevant issue(s)

Resolves #3402

Description

In light of this PR:
https://github.com/sourcenetwork/defradb/pull/3400/files

I did a rip grep search:

 rg -U "if err != nil \{\n.*return nil$"

And found one more instance in the code base where non-nill error would still returning nil.

@shahzadlone shahzadlone added the code quality Related to improving code quality label Jan 21, 2025
@shahzadlone shahzadlone added this to the DefraDB v0.16 milestone Jan 21, 2025
@shahzadlone shahzadlone self-assigned this Jan 21, 2025
Copy link

codecov bot commented Jan 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 78.20%. Comparing base (486f9da) to head (fca1262).
Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #3403      +/-   ##
===========================================
- Coverage    78.24%   78.20%   -0.04%     
===========================================
  Files          392      392              
  Lines        36045    36045              
===========================================
- Hits         28202    28188      -14     
- Misses        6175     6184       +9     
- Partials      1668     1673       +5     
Flag Coverage Δ
all-tests 78.20% <ø> (-0.04%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

see 12 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 486f9da...fca1262. Read the comment docs.

@shahzadlone shahzadlone requested a review from a team January 21, 2025 15:23
Copy link
Contributor

@AndrewSisley AndrewSisley left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for checking this Shahzad :)

@shahzadlone shahzadlone merged commit 727800a into sourcenetwork:develop Jan 21, 2025
42 of 44 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code quality Related to improving code quality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Non nill error should not return nil
2 participants