mirror of
https://github.com/gitui-org/gitui
synced 2026-05-24 09:28:21 +00:00
Fixed:
- Cargo clippy errors Updated: - Ran cargo clippy --fix - Ran cargo fmt
This commit is contained in:
parent
02dfae7bd4
commit
5dd1852dd3
5 changed files with 7 additions and 11 deletions
|
|
@ -756,7 +756,7 @@ mod tests {
|
|||
if let Some(ta) = &mut comp.textarea {
|
||||
let txt = ta.lines();
|
||||
assert_eq!(txt[0].len(), 1);
|
||||
assert_eq!(txt[0].as_bytes()[0], 'a' as u8);
|
||||
assert_eq!(txt[0].as_bytes()[0], b'a');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -404,9 +404,9 @@ mod tests {
|
|||
)
|
||||
.unwrap();
|
||||
|
||||
assert_eq!(res.multiple_items_at_path(0), false);
|
||||
assert_eq!(res.multiple_items_at_path(1), false);
|
||||
assert_eq!(res.multiple_items_at_path(2), true);
|
||||
assert!(!res.multiple_items_at_path(0));
|
||||
assert!(!res.multiple_items_at_path(1));
|
||||
assert!(res.multiple_items_at_path(2));
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
|||
|
|
@ -509,10 +509,7 @@ mod tests {
|
|||
false, //
|
||||
]
|
||||
);
|
||||
assert_eq!(
|
||||
res.is_visible_index(res.selection.unwrap()),
|
||||
true
|
||||
);
|
||||
assert!(res.is_visible_index(res.selection.unwrap()));
|
||||
assert_eq!(res.selection, Some(0));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -197,8 +197,7 @@ impl Component for BlameFilePopup {
|
|||
let has_result = self
|
||||
.blame
|
||||
.as_ref()
|
||||
.map(|blame| blame.result().is_some())
|
||||
.unwrap_or_default();
|
||||
.is_some_and(|blame| blame.result().is_some());
|
||||
if self.is_visible() || force_all {
|
||||
out.push(
|
||||
CommandInfo::new(
|
||||
|
|
|
|||
|
|
@ -445,7 +445,7 @@ mod test {
|
|||
"mnopab cdefghi j",
|
||||
"klmno",
|
||||
]
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
|
|||
Loading…
Reference in a new issue