karma-spec-reporter
karma-spec-reporter copied to clipboard
Show object diff when chai deepEqual fails - feature request
When an assertion using deep.equals fails, it would be nice to get a detailed output that shows piece by piece what is different between the expected and actual values. Something like:
Can you provide the dependency for the deepEqual method? Jasmine does not appear to have it, but Chai does. Just want to gather some more information. Thanks!
Sure: https://github.com/chaijs/deep-eql
karma-mocha-reporter
has this feature implemented:
https://github.com/litixsoft/karma-mocha-reporter/blob/master/index.js#L373
so it may be good inspiration point.
Would you be willing to put a PR up? There is a little bit of work since we enforce TDD. Thanks for the help, I haven't had as much time to contribute recently. I'm still surprised with the amount of people using this since Webpack is the "future".
Closing as this is old and only one person has commented. Will re-open if someone else requests it or if they have a PR ready to go