Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 99b5443

Browse files
committed
cargo fmt
1 parent dcff2ee commit 99b5443

1 file changed

Lines changed: 55 additions & 26 deletions

File tree

src/interactive/app/tests/journeys_readonly.rs

Lines changed: 55 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -134,42 +134,63 @@ fn simple_user_journey_read_only() -> Result<()> {
134134
// Columns
135135
{
136136
// hit the C key shows the entry count column
137-
app.process_events(&mut terminal, into_events([
138-
Event::Key(KeyEvent::new(KeyCode::Char('C'), KeyModifiers::NONE)),
139-
]))?;
137+
app.process_events(
138+
&mut terminal,
139+
into_events([Event::Key(KeyEvent::new(
140+
KeyCode::Char('C'),
141+
KeyModifiers::NONE,
142+
))]),
143+
)?;
140144
assert!(app.state.show_columns.contains(&Column::Count));
141145

142146
// when hitting the C key again hides the entry count column
143-
app.process_events(&mut terminal, into_events([
144-
Event::Key(KeyEvent::new(KeyCode::Char('C'), KeyModifiers::NONE)),
145-
]))?;
147+
app.process_events(
148+
&mut terminal,
149+
into_events([Event::Key(KeyEvent::new(
150+
KeyCode::Char('C'),
151+
KeyModifiers::NONE,
152+
))]),
153+
)?;
146154
assert!(!app.state.show_columns.contains(&Column::Count));
147155

148156
// hit the M key shows the entry count column
149-
app.process_events(&mut terminal, into_events([
150-
Event::Key(KeyEvent::new(KeyCode::Char('M'), KeyModifiers::NONE)),
151-
]))?;
157+
app.process_events(
158+
&mut terminal,
159+
into_events([Event::Key(KeyEvent::new(
160+
KeyCode::Char('M'),
161+
KeyModifiers::NONE,
162+
))]),
163+
)?;
152164
assert!(app.state.show_columns.contains(&Column::MTime));
153165

154166
// when hitting the M key again hides the entry count column
155-
app.process_events(&mut terminal, into_events([
156-
Event::Key(KeyEvent::new(KeyCode::Char('M'), KeyModifiers::NONE)),
157-
]))?;
167+
app.process_events(
168+
&mut terminal,
169+
into_events([Event::Key(KeyEvent::new(
170+
KeyCode::Char('M'),
171+
KeyModifiers::NONE,
172+
))]),
173+
)?;
158174
assert!(!app.state.show_columns.contains(&Column::MTime));
159175
}
160176

161177
// Glob pane open/close
162178
{
163179
// '/' shows the glob pane
164-
app.process_events(&mut terminal, into_events([
165-
Event::Key(KeyEvent::new(KeyCode::Char('/'), KeyModifiers::NONE)),
166-
]))?;
180+
app.process_events(
181+
&mut terminal,
182+
into_events([Event::Key(KeyEvent::new(
183+
KeyCode::Char('/'),
184+
KeyModifiers::NONE,
185+
))]),
186+
)?;
167187
assert!(app.window.glob_pane.is_some());
168188

169189
// ESC closes the glob pane
170-
app.process_events(&mut terminal, into_events([
171-
Event::Key(KeyEvent::new(KeyCode::Esc, KeyModifiers::NONE)),
172-
]))?;
190+
app.process_events(
191+
&mut terminal,
192+
into_events([Event::Key(KeyEvent::new(KeyCode::Esc, KeyModifiers::NONE))]),
193+
)?;
173194
assert!(app.window.glob_pane.is_none());
174195
}
175196

@@ -178,11 +199,15 @@ fn simple_user_journey_read_only() -> Result<()> {
178199
assert!(app.state.scan.is_none());
179200

180201
// 'R' refreshes all entries in the view
181-
app.process_events(&mut terminal, into_events([
182-
Event::Key(KeyEvent::new(KeyCode::Char('R'), KeyModifiers::NONE)),
183-
]))?;
202+
app.process_events(
203+
&mut terminal,
204+
into_events([Event::Key(KeyEvent::new(
205+
KeyCode::Char('R'),
206+
KeyModifiers::NONE,
207+
))]),
208+
)?;
184209
assert!(app.state.scan.is_some());
185-
210+
186211
// refresh should finish eventually
187212
app.run_until_traversed(&mut terminal, into_events([]))?;
188213
assert!(app.state.scan.is_none());
@@ -201,11 +226,15 @@ fn simple_user_journey_read_only() -> Result<()> {
201226
);
202227

203228
// 'R' refreshes all entries in the view
204-
app.process_events(&mut terminal, into_events([
205-
Event::Key(KeyEvent::new(KeyCode::Char('R'), KeyModifiers::NONE)),
206-
]))?;
229+
app.process_events(
230+
&mut terminal,
231+
into_events([Event::Key(KeyEvent::new(
232+
KeyCode::Char('R'),
233+
KeyModifiers::NONE,
234+
))]),
235+
)?;
207236
assert!(app.state.scan.is_some());
208-
237+
209238
// Refresh should finish
210239
app.run_until_traversed(&mut terminal, into_events([]))?;
211240
assert!(app.state.scan.is_none());

0 commit comments

Comments
 (0)