MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_total_lines

Function test_total_lines

atomic-core/src/diff/display.rs:983–991  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

981
982 #[test]
983 fn test_total_lines() {
984 let old = b"a\nb\nc\n";
985 let new = b"a\nx\ny\nc\n";
986 let diff = UnifiedDiff::new(old, new, Algorithm::Myers);
987
988 let total = diff.total_lines();
989 let actual: Vec<_> = diff.lines().collect();
990 assert_eq!(actual.len(), total);
991 }
992}

Callers

nothing calls this directly

Calls 2

total_linesMethod · 0.45
linesMethod · 0.45

Tested by

no test coverage detected