Skip to content

assert: adjust loose assertions

This changes the loose deep equal comparison by using the same logic as done in the strict deep equal comparison besides comparing primitives loosely, not comparing symbol properties and not comparing the prototype.

assert.deepEqual is still commenly used and this is likely the biggest pitfall.

Most changes are only minor and won't have a big impact besides likely fixing user expectations.

I guess this might still be a bit bold but I believe it's the right thing to do. We just have to check how much impact this has in userland.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

Merge request reports

Loading