Increase test coverage for core vector classes to 100% #4
+341
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Test coverage for core vector classes (Vector, HalfVector, Bit, SparseVector) was at 66-82%, with critical database conversion methods and edge cases untested.
Changes
Database Adapter Coverage
_to_db(),_to_db_binary(),_from_db(),_from_db_binary()methodsSerialization Coverage
to_text(),from_text(),to_binary(),from_binary()tests for Bit classEdge Cases
Vector([1,2,3]) != [1,2,3])Error Conditions
_to_db(dim=N)_to_db()methodsCoverage Impact
Test count: 58 → 135 (+77 tests)
Note: SparseVector's missing 1% is scipy version compatibility code at line 90 (fallback for scipy <1.13).
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.