From c4bbdd03c52c6be34717f39a89a7bfdc999ecc45 Mon Sep 17 00:00:00 2001 From: "gcp-cherry-pick-bot[bot]" <98988430+gcp-cherry-pick-bot[bot]@users.noreply.github.com> Date: Fri, 4 Apr 2025 09:18:20 -0400 Subject: [PATCH] Temporarily disable flaky conflicted-cherry-pick test (cherry-pick #27950) (#28087) Cherry-picked Temporarily disable flaky conflicted-cherry-pick test (#27950) Closes #ISSUE Release Notes: - N/A Co-authored-by: Cole Miller --- crates/project/src/project_tests.rs | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/crates/project/src/project_tests.rs b/crates/project/src/project_tests.rs index d9ffd8590f095b9ed85f042d936db326e6707d5e..e3dd9f9a8f95e20b9d6c062f23e258824c5f772c 100644 --- a/crates/project/src/project_tests.rs +++ b/crates/project/src/project_tests.rs @@ -7434,9 +7434,8 @@ async fn test_repository_subfolder_git_status(cx: &mut gpui::TestAppContext) { }); } -// TODO: this test fails on Windows because upon cherry-picking we don't get an event in the .git directory, -// despite CHERRY_PICK_HEAD existing after the `git_cherry_pick` call and the conflicted path showing up in git status. -#[cfg(not(windows))] +// TODO: this test is flaky (especially on Windows but at least sometimes on all platforms). +#[cfg(any())] #[gpui::test] async fn test_conflicted_cherry_pick(cx: &mut gpui::TestAppContext) { init_test(cx); @@ -8312,7 +8311,7 @@ fn git_commit(msg: &'static str, repo: &git2::Repository) { } } -#[cfg(not(windows))] +#[cfg(any())] #[track_caller] fn git_cherry_pick(commit: &git2::Commit<'_>, repo: &git2::Repository) { repo.cherrypick(commit, None).expect("Failed to cherrypick"); @@ -8343,7 +8342,7 @@ fn git_reset(offset: usize, repo: &git2::Repository) { .expect("Could not reset"); } -#[cfg(not(windows))] +#[cfg(any())] #[track_caller] fn git_branch(name: &str, repo: &git2::Repository) { let head = repo @@ -8354,14 +8353,14 @@ fn git_branch(name: &str, repo: &git2::Repository) { repo.branch(name, &head, false).expect("Failed to commit"); } -#[cfg(not(windows))] +#[cfg(any())] #[track_caller] fn git_checkout(name: &str, repo: &git2::Repository) { repo.set_head(name).expect("Failed to set head"); repo.checkout_head(None).expect("Failed to check out head"); } -#[cfg(not(windows))] +#[cfg(any())] #[track_caller] fn git_status(repo: &git2::Repository) -> collections::HashMap { repo.statuses(None)