()
| 975 | |
| 976 | #[test] |
| 977 | fn test_change_hunk_try_extract() { |
| 978 | let content = b"hello"; |
| 979 | let valid = ChangeHunk::new(0, 3, HunkKind::Deleted); |
| 980 | assert_eq!(valid.try_extract(content), Some(&b"hel"[..])); |
| 981 | |
| 982 | let invalid = ChangeHunk::new(0, 100, HunkKind::Deleted); |
| 983 | assert_eq!(invalid.try_extract(content), None); |
| 984 | } |
| 985 | |
| 986 | #[test] |
| 987 | fn test_change_hunk_display() { |
nothing calls this directly
no outgoing calls
no test coverage detected