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

assert.eq always returns true for javascript Set objects

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Testing Infrastructure
    • None
    • Server Tooling & Methods
    • 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

        Activity

          People

            backlog-server-stm Backlog - Server Tooling and Methods (STM) (Inactive)
            ian.boros@mongodb.com Ian Boros
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: