Skip to content

Commit d7fa2a9

Browse files
committed
Improved typechecking for tests [skip ci]
1 parent 587d652 commit d7fa2a9

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

tests/utils.test.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ import { SparseVector } from 'pgvector';
55

66
test('fromSql', () => {
77
assert.deepEqual(pgvector.fromSql('[1,2,3]'), [1, 2, 3]);
8-
// @ts-ignore
9-
assert.deepEqual(pgvector.fromSql('{1:1,2:2,3:3}/3').toArray(), [1, 2, 3]);
8+
assert.deepEqual(pgvector.fromSql('{1:1,2:2,3:3}/3'), new SparseVector([1, 2, 3]));
109
assert.equal(pgvector.fromSql(null), null);
1110
assert.throws(() => pgvector.fromSql(''), {message: 'invalid text representation'});
1211
});

0 commit comments

Comments
 (0)