-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
enhancementenhancement: colored outputAbout adding colored outputAbout adding colored outputenhancement: output formatEnhancement related to formatting of messagesEnhancement related to formatting of messagespkg-assertChange related to package testify/assertChange related to package testify/assert
Description
When running tests in IDE/text editor, it's difficult to analyze the diffs produced by assert.Equal without somehow highlighting the different lines. This could be improved by making diff colorized. That is, make the "expected" lines red and make the "actual" lines green. The result could be similar to what https://github.com/mcmire/super_diff/tree/main provides
Teistify uses difflib that is no longer maintained and cannot be extended to modify the diff structure, so it might be better to switch to another library: https://github.com/sergi/go-diff. It provides structured diffs and can be used to colorize the output
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementenhancement: colored outputAbout adding colored outputAbout adding colored outputenhancement: output formatEnhancement related to formatting of messagesEnhancement related to formatting of messagespkg-assertChange related to package testify/assertChange related to package testify/assert