• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

dandavison / delta / 6914707237

18 Nov 2023 03:11PM UTC coverage: 59.338% (+1.1%) from 58.209%
6914707237

push

github

web-flow
fixed typos (#1553)

2386 of 4021 relevant lines covered (59.34%)

1.9 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

66.67
/src/handlers/diff_header_diff.rs
1
use crate::delta::{DiffType, InMergeConflict, MergeParents, State, StateMachine};
2

3
impl<'a> StateMachine<'a> {
4
    #[inline]
5
    fn test_diff_header_diff_line(&self) -> bool {
×
6
        self.line.starts_with("diff ")
×
7
    }
8

9
    #[allow(clippy::unnecessary_wraps)]
10
    pub fn handle_diff_header_diff_line(&mut self) -> std::io::Result<bool> {
4✔
11
        if !self.test_diff_header_diff_line() {
2✔
12
            return Ok(false);
2✔
13
        }
14
        self.painter.paint_buffered_minus_and_plus_lines();
2✔
15
        self.state =
2✔
16
            if self.line.starts_with("diff --cc ") || self.line.starts_with("diff --combined ") {
6✔
17
                // We will determine the number of parents when we see the hunk header.
18
                State::DiffHeader(DiffType::Combined(
×
19
                    MergeParents::Unknown,
×
20
                    InMergeConflict::No,
×
21
                ))
22
            } else {
23
                State::DiffHeader(DiffType::Unified)
×
24
            };
25
        self.handle_pending_line_with_diff_name()?;
4✔
26
        self.handled_diff_header_header_line_file_pair = None;
2✔
27
        self.diff_line = self.line.clone();
4✔
28
        if !self.should_skip_line() {
2✔
29
            self.emit_line_unchanged()?;
2✔
30
        }
31
        Ok(true)
2✔
32
    }
33
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc