[SERVER-21893] JS tests that use dbHash incorrectly check number of collections Created: 14/Dec/15  Updated: 16/Nov/16  Resolved: 21/Dec/15

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: 3.2.1, 3.3.0

Type: Bug Priority: Major - P3
Reporter: Kamran K. Assignee: Jonathan Abrahams
Resolution: Done Votes: 0
Labels: test-only
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-21768 Remove the 'numCollections' field fro... Closed
Backwards Compatibility: Fully Compatible
Backport Completed:
Sprint: TIG E (01/08/16)
Participants:

 Description   

max.hirschhorn noticed that the fix for SERVER-21768 incorrectly checks .length fields on objects. For example, in this change, .length is now being called on a 'collections' object.

assert.eq(masterHashes.collections.length,
-                              slaveHashes.numCollections,
+                              slaveHashes.collections.length,

We should fix the tests to compare Object.keys() counts instead.



 Comments   
Comment by Githook User [ 21/Dec/15 ]

Author:

{u'username': u'hptabster', u'name': u'Jonathan Abrahams', u'email': u'jonathan@mongodb.com'}

Message: SERVER-21893 Fix dbHash result check for number of collections.

(cherry picked from commit df25ea8ff2dd2fdc94b5f4cd39b15606aee1dd3b)
Branch: v3.2
https://github.com/mongodb/mongo/commit/26e9dec5ab8cad307db7795dd0ff74565396199a

Comment by Githook User [ 21/Dec/15 ]

Author:

{u'username': u'hptabster', u'name': u'Jonathan Abrahams', u'email': u'jonathan@mongodb.com'}

Message: SERVER-21893 Fix dbHash result check for number of collections.
Branch: master
https://github.com/mongodb/mongo/commit/df25ea8ff2dd2fdc94b5f4cd39b15606aee1dd3b

Generated at Thu Feb 08 03:58:44 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.