Skip to content

Commit 400e752

Browse files
committed
snapshot test infrastructure
sets up insta for reliable graph snapshots
1 parent 092201b commit 400e752

4 files changed

Lines changed: 54 additions & 1 deletion

File tree

src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ type Terminal = ratatui::Terminal<CrosstermBackend<io::Stdout>>;
114114
static TICK_INTERVAL: Duration = Duration::from_secs(5);
115115
static SPINNER_INTERVAL: Duration = Duration::from_millis(80);
116116

117-
///
117+
/// Events sent to the event-loop to wake up the UI.
118118
#[derive(Clone)]
119119
pub enum QueueEvent {
120120
Tick,
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
source: src/gitui.rs
3+
assertion_line: 359
4+
expression: terminal.backend()
5+
---
6+
" Status [1] | Log [2] | Files [3] | Stashing [4] | Stashes [5][TEMP_FILE] "
7+
" ──────────────────────────────────────────────────────────────────────────────────────── "
8+
"┌Commit 3/3──────────────────────────────────────────────────────────────────────────────┐"
9+
"│[COMMIT] <1m ago name commit B █"
10+
"│[COMMIT] <1m ago name commit A ║"
11+
"│[COMMIT] <1m ago name initial ║"
12+
"│ ║"
13+
"│ ║"
14+
"│ ║"
15+
"│ ║"
16+
"└────────────────────────────────────────────────────────────────────────────────────────┘"
17+
"Scroll [↑↓] Mark [˽] Toggle Graph [g] Details [⏎] Branches [b] Compare [⇧C] more [.]"
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
source: src/gitui.rs
3+
assertion_line: 341
4+
expression: terminal.backend()
5+
---
6+
" Status [1] | Log [2] | Files [3] | Stashing [4] | Stashes [5][TEMP_FILE] "
7+
" ──────────────────────────────────────────────────────────────────────────────────────── "
8+
"┌Commit 3/3──────────────────────────────────────────────────────────────────────────────┐"
9+
"│o [COMMIT] <1m ago name commit B █"
10+
"│o [COMMIT] <1m ago name commit A ║"
11+
"│o [COMMIT] <1m ago name initial ║"
12+
"│ ║"
13+
"│ ║"
14+
"│ ║"
15+
"│ ║"
16+
"└────────────────────────────────────────────────────────────────────────────────────────┘"
17+
"Scroll [↑↓] Mark [˽] Toggle Graph [g] Details [⏎] Branches [b] Compare [⇧C] more [.]"
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
source: src/gitui.rs
3+
assertion_line: 375
4+
expression: terminal.backend()
5+
---
6+
" Status [1] | Log [2] | Files [3] | Stashing [4] | Stashes [5][TEMP_FILE] "
7+
" ──────────────────────────────────────────────────────────────────────────────────────── "
8+
"┌Commit 4/4──────────────────────────────────────────────────────────────────────────────┐"
9+
"│M━┓ [COMMIT] <1m ago name merge C into main █"
10+
"│o ┃ [COMMIT] <1m ago name commit A ║"
11+
"│┃ o [COMMIT] <1m ago name commit C ║"
12+
"│o━┛ [COMMIT] <1m ago name initial ║"
13+
"│ ║"
14+
"│ ║"
15+
"│ ║"
16+
"│ ║"
17+
"│ ║"
18+
"└────────────────────────────────────────────────────────────────────────────────────────┘"
19+
"Scroll [↑↓] Mark [˽] Toggle Graph [g] Details [⏎] Branches [b] Compare [⇧C] more [.]"

0 commit comments

Comments
 (0)