Skip to content

Bug in dictionary equality #5

@sm-g

Description

@sm-g

this test fails

       public void Test()
       {
           var dico1 = new Dictionary<int, string>() { { 1, "uno" }, { 3, "tres" } };
           var dico2 = new Dictionary<int, string>() { { 1, "uno" }, { 3, "tres" }, { 4, "quatro" } };

           var byValue1 = new DictionaryByValue<int, string>(dico1);
           var byValue2 = new DictionaryByValue<int, string>(dico2);

           Check.That(byValue1).IsNotEqualTo(byValue2);
       }

For anyone who also ran into it - you may use my ByValue library, which have no such issue (see these tests).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions