Skip to main content

diff

Function diff 

Source
pub fn diff(expected: &str, actual: &str) -> Option<String>
Expand description

A line-level difference between two renderings.

Comparing the whole rendering with assert_eq! reports two multi-line strings as two opaque blobs, which is exactly the moment a guard stops being read and starts being overridden. Report the lines that moved.