-
Notifications
You must be signed in to change notification settings - Fork 118
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:add tests for fileinfo.go #1138
base: main
Are you sure you want to change the base?
Conversation
Thanks for making a pull request! 😃 |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1138 +/- ##
==========================================
+ Coverage 14.85% 14.95% +0.09%
==========================================
Files 90 90
Lines 8379 8379
==========================================
+ Hits 1245 1253 +8
+ Misses 6813 6805 -8
Partials 321 321 ☔ View full report in Codecov by Sentry. |
@kmehant @seshapad @HarikrishnanBalagopal I have raised a PR for testing fileinfo.go. Please have a look |
@satyazzz123 thank you for the PR. Shall we close this PR (#1124) first before we move on to new ones? Please update the PR when you are able to and let us know. Appreciate your contributions. |
Almost done with the changes will push those changes for #1124 . Sorry for the delay. |
expectedName := "testfile.txt" | ||
fileInfo := &FileInfo{ | ||
stat: types.ContainerPathStat{ | ||
Name: expectedName, | ||
}, | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets try getting types.ContainerPathStat
from any simple operation rather than constructing it ourselves and then pass it. We are not actually testing much here by constructing the struct ourselves.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets try the same (#1138 (comment)) for all of your other test functions in this PR. Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it working on the requested changes
Signed-off-by: satyazzz123 <[email protected]>
3247b4f
to
b682725
Compare
Signed-off-by: satyazzz123 <[email protected]>
added tests for fileinfo.go functions
fixes a part of: #884