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

Add test for getExtension method in Embedding class #1134

Conversation

harshpreet08
Copy link
Contributor

Pull Request Summary

This pull request introduces a new test case in the EmbeddingTest class, specifically in the getExtension method. The test, named getExtension_UsesExtensionFromNameWhenMIMETypeIsUnknown, verifies that the method correctly retrieves the file extension from the name when the MIME type is unknown. This improvement makes sure our code handles unknown file types more effectively and adds to the overall coverage of our code tests.

Your review of the changes is appreciated. Thank you!

Copy link

codecov bot commented Dec 27, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (7375184) 97.11% compared to head (410833f) 97.11%.

Additional details and impacted files
@@            Coverage Diff            @@
##             master    #1134   +/-   ##
=========================================
  Coverage     97.11%   97.11%           
  Complexity      555      555           
=========================================
  Files            55       55           
  Lines          1212     1212           
  Branches        106      106           
=========================================
  Hits           1177     1177           
  Misses           20       20           
  Partials         15       15           

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

- Introduce a new test case to ensure correct behavior of the getExtension method.
- Enhance coverage for the Embedding class, specifically validating its handling of unknown MIME types.
@damianszczepanik damianszczepanik force-pushed the enhancement/add-embedding-test branch from de6fe84 to 410833f Compare December 27, 2023 16:59
@damianszczepanik damianszczepanik merged commit bf539ce into damianszczepanik:master Dec 27, 2023
7 checks passed
@damianszczepanik
Copy link
Owner

Nice test!

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.

2 participants