From cdbbde164b77b99ea031adbb4393a21e26a97317 Mon Sep 17 00:00:00 2001 From: Ilya Grigoriev Date: Sat, 3 Feb 2024 19:13:25 -0800 Subject: [PATCH] test_git_push: clarify the initial setup --- cli/tests/test_git_push.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/cli/tests/test_git_push.rs b/cli/tests/test_git_push.rs index ec44760c8..b6e8406ae 100644 --- a/cli/tests/test_git_push.rs +++ b/cli/tests/test_git_push.rs @@ -51,6 +51,14 @@ fn set_up() -> (TestEnvironment, PathBuf) { #[test] fn test_git_push_nothing() { let (test_env, workspace_root) = set_up(); + // Show the setup. `insta` has trouble if this is done inside `set_up()` + let stdout = test_env.jj_cmd_success(&workspace_root, &["branch", "list", "--all"]); + insta::assert_snapshot!(stdout, @r###" + branch1: lzmmnrxq 45a3aa29 (empty) description 1 + @origin: lzmmnrxq 45a3aa29 (empty) description 1 + branch2: rlzusymt 8476341e (empty) description 2 + @origin: rlzusymt 8476341e (empty) description 2 + "###); // No branches to push yet let (stdout, stderr) = test_env.jj_cmd_ok(&workspace_root, &["git", "push", "--all"]); insta::assert_snapshot!(stdout, @"");