Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
imsnif committed Aug 7, 2024
1 parent a66aba1 commit fb4d73a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
6 changes: 5 additions & 1 deletion zellij-server/src/plugins/unit/plugin_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6873,5 +6873,9 @@ pub fn open_command_pane_background_plugin_command() {
}
})
.clone();
assert_snapshot!(format!("{:#?}", new_tab_event));
// we do the replace below to avoid the randomness of the temporary folder in the snapshot
// while still testing it
assert_snapshot!(
format!("{:#?}", new_tab_event).replace(&format!("{:?}", temp_folder.path()), "\"CWD\"")
);
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
source: zellij-server/src/plugins/./unit/plugin_tests.rs
assertion_line: 6876
expression: "format!(\"{:#?}\", new_tab_event)"
assertion_line: 6878
expression: "format!(\"{:#?}\",\n new_tab_event).replace(&format!(\"{:?}\", temp_folder.path()),\n \"\\\"CWD\\\"\")"
---
Some(
SpawnTerminal(
Expand All @@ -13,7 +13,9 @@ Some(
"arg1",
"arg2",
],
cwd: None,
cwd: Some(
"CWD",
),
hold_on_close: true,
hold_on_start: false,
originating_plugin: Some(
Expand Down

0 comments on commit fb4d73a

Please sign in to comment.