You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How it can be achieved? I propose to use a diff-match Lua module 1 for comparing strings, Tables should be serialized to YAML before comparing. Msgpack buffers should be decoded and serialized to YAML if it is a table.
luatest has an
is_equal
/is_not_equal
assertions.Currently, output for tables/multiline strings/msgpack buffers looks as the following:
code
Tables:
Multiline strings:
msgpack:
This output is not convenient for debugging.
I propose to print a diff for this data in case of triggered assertion. This would be much more convenient to get a difference in comparison:
String:
Tables:
How it can be achieved? I propose to use a diff-match Lua module 1 for comparing strings, Tables should be serialized to YAML before comparing. Msgpack buffers should be decoded and serialized to YAML if it is a table.
See also:
Footnotes
https://github.com/google/diff-match-patch/blob/master/lua/diff_match_patch.lua ↩
The text was updated successfully, but these errors were encountered: