Skip to content

Compare Maps and Sets #54

Closed
Closed

Description

@mattiasholmlund

@substack wrote in tape-testing/tape#342:

Once this is merged into core I will release a new major version of deep-equal based on the new algorithm that tape can be updated to support.

As far as I can see, node 8 has a deepEqual that can properly compare Maps and Sets:

node-v8.9.4-linux-x64 $ ./bin/node
> const assert = require('assert')
undefined
> assert.deepEqual(new Set('a'), new Set('a'))
undefined
> assert.deepEqual(new Set('a'), new Set('b'))
AssertionError [ERR_ASSERTION]: Set { 'a' } deepEqual Set { 'b' }
>

I find Sets and Maps very useful and want to use them with t.deepEqual() in tape.

Activity

  1. kumavis commented on Aug 30, 2019

    @kumavis

    +1 to this feature, and seeing it get into tape

  2. simoelmou commented on Sep 25, 2019

    @simoelmou

    +1 to this feature

  3. added 2 commits that reference this issue on Dec 1, 2019
    2a4c42d
    47eb288
  4. added a commit that references this issue on Dec 1, 2019
    20877c4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions