Browse Source
1) JSON does not guarantee the ordering that fields are encoded in the string, making it unreliable for generic hashing. 2) When ordering is maintained, the strings match the ordering the fields were added to the object, making the unit test too tighly coupled to the order they are added in the implementation. 3) A field whose value is undefined versus not being present presents a difference that deepEqual should assert. If it does not matter then possibly a different assert should be used.pull/724/head
1 changed files with 7 additions and 4 deletions
Loading…
Reference in new issue