Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-40107

assert.eq always returns true for javascript Set objects

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Testing Infrastructure
    • Labels:
      None
    • Operating System:
      ALL

      Description

      This assertion passes:

      assert.eq(new Set([1,2]), new Set([1]))
      

      Looks like it's because if we tojson() a Set we get an empty object:

      > tojson(new Set([1,2]))
      { }
      

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: