Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,9 @@ impl Environment {
use crossbeam_channel::unbounded;
Self {
queue: Queue::new(),
theme: Default::default(),
key_config: Default::default(),
repo: RefCell::new(RepoPath::Path(Default::default())),
theme: Rc::default(),
key_config: Rc::default(),
repo: RefCell::new(RepoPath::Path(PathBuf::default())),
options: Rc::new(RefCell::new(Options::test_env())),
sender_git: unbounded().0,
sender_app: unbounded().0,
Expand Down
2 changes: 1 addition & 1 deletion src/components/diff.rs
Original file line number Diff line number Diff line change
Expand Up @@ -957,7 +957,7 @@ mod tests {
let diff_line = DiffLine {
content: "".into(),
line_type: DiffLineType::Add,
position: Default::default(),
position: DiffLinePosition::default(),
};

{
Expand Down
4 changes: 2 additions & 2 deletions src/options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ impl Options {
pub fn test_env() -> Self {
use asyncgit::sync::RepoPath;
Self {
repo: RefCell::new(RepoPath::Path(Default::default())),
data: Default::default(),
repo: RefCell::new(RepoPath::Path(PathBuf::default())),
data: OptionsData::default(),
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/ui/reflow.rs
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ mod test {
text: &str,
text_area_width: u16,
) -> (Vec<String>, Vec<u16>) {
let style = Default::default();
let style = ratatui::style::Style::default();
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wasn't sure if Style::default(), with an additional import at the top, would be preferable here.

let mut styled = UnicodeSegmentation::graphemes(text, true)
.map(|g| StyledGrapheme { symbol: g, style });
let mut composer: Box<dyn LineComposer> = match which {
Expand Down