From 439789f6b6c57864de07638e4c3151925635e21c Mon Sep 17 00:00:00 2001 From: messense Date: Sun, 7 May 2023 22:23:21 +0800 Subject: [PATCH] Skip git sdist generator tests when executing from a non-git checkout --- tests/run.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/run.rs b/tests/run.rs index dea8dedad..bbdc4ffac 100644 --- a/tests/run.rs +++ b/tests/run.rs @@ -575,6 +575,9 @@ fn pyo3_mixed_include_exclude_sdist() { #[test] fn pyo3_mixed_include_exclude_git_sdist_generator() { + if !Path::new(".git").exists() { + return; + } handle_result(other::test_source_distribution( "test-crates/pyo3-mixed-include-exclude", SdistGenerator::Git, @@ -659,6 +662,9 @@ fn workspace_with_path_dep_sdist() { #[test] fn workspace_with_path_dep_git_sdist_generator() { + if !Path::new(".git").exists() { + return; + } handle_result(other::test_source_distribution( "test-crates/workspace_with_path_dep/python", SdistGenerator::Git,