Skip to content
Merged
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
16 changes: 16 additions & 0 deletions src/cmds/git/git.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2077,6 +2077,22 @@ mod tests {
assert!(result.contains("stash@{1}: def5678 wip"));
}

#[test]
fn test_run_stash_list_propagates_failure() {
let dir = tempfile::tempdir().expect("tempdir");
let global = vec!["-C".to_string(), dir.path().to_string_lossy().into_owned()];
let code = run_stash(Some("list"), &[], 0, &global).expect("run_stash list");
assert_ne!(code, 0, "git stash list failure must propagate");
}

#[test]
fn test_run_stash_show_propagates_failure() {
let dir = tempfile::tempdir().expect("tempdir");
let global = vec!["-C".to_string(), dir.path().to_string_lossy().into_owned()];
let code = run_stash(Some("show"), &[], 0, &global).expect("run_stash show");
assert_ne!(code, 0, "git stash show failure must propagate");
}

#[test]
fn test_filter_worktree_list() {
let output =
Expand Down
Loading