Skip to content

Commit 9174783

Browse files
authored
test: Replace dead row length check with similar shape check (#3532)
These object-mode rows don’t include a `length`. Dead code since 721cf56 (“Rows are now associative arrays rather than straight arrays.”)?
1 parent f5c90a5 commit 9174783

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

packages/pg/test/integration/client/simple-query-tests.js

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,8 @@ test('simple query interface', function () {
1919
rows.push(row['name'])
2020
})
2121
query.once('row', function (row) {
22-
test('Can iterate through columns', function () {
23-
const columnCount = Object.keys(row).length
24-
if ('length' in row) {
25-
assert.lengthIs(
26-
row,
27-
columnCount,
28-
'Iterating through the columns gives a different length from calling .length.'
29-
)
30-
}
22+
test('returned right columns', function () {
23+
assert.deepStrictEqual(row, { name: row.name })
3124
})
3225
})
3326

0 commit comments

Comments
 (0)