cypress icon indicating copy to clipboard operation
cypress copied to clipboard

Show diffs for assertions logged in browser console

Open kuceb opened this issue 7 years ago • 5 comments

Add diffs to assertion errors in cypress open mode

Current:

19-01-14_11 55 28

Desired:

image

In run mode, we already have diffs:

image

nice-to-haves:

  • [x] collapse-able log block in console
  • [ ] show inline diff for long strings
  • [ ] use background color to show exactly what is different in each line (possible add this to the cypress run reporter

kuceb avatar Jan 14 '19 16:01 kuceb

nice, this would be great for user experience

bahmutov avatar Jan 14 '19 21:01 bahmutov

Has this been added to cypress yet? Would love this feature

TheKnightCoder avatar Dec 10 '20 15:12 TheKnightCoder

@TheKnightCoder No, the issue will be closed when it is in the product.

jennifer-shehane avatar Dec 11 '20 10:12 jennifer-shehane

@jennifer-shehane Any updates on this or any timeline for this ? This would make life easy for most of us

gurudattgd04 avatar Feb 26 '22 06:02 gurudattgd04

I would recommend the visual diff feature showed off by https://github.com/benjamine/jsondiffpatch. If possible I think it would be really great to embed the visual diff feature by default for deep equality failures.

jpierson-at-riis avatar Oct 23 '24 01:10 jpierson-at-riis