aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe/tests/package
diff options
context:
space:
mode:
Diffstat (limited to 'crates/shirabe/tests/package')
-rw-r--r--crates/shirabe/tests/package/loader/root_package_loader_test.rs12
-rw-r--r--crates/shirabe/tests/package/version/version_guesser_test.rs3
2 files changed, 1 insertions, 14 deletions
diff --git a/crates/shirabe/tests/package/loader/root_package_loader_test.rs b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
index 069cf5a7..248c4e6a 100644
--- a/crates/shirabe/tests/package/loader/root_package_loader_test.rs
+++ b/crates/shirabe/tests/package/loader/root_package_loader_test.rs
@@ -5,6 +5,7 @@
// look-around regex the regex crate cannot compile.
use crate::process_executor_mock::{cmd, cmd_full, get_process_executor_mock};
+use crate::test_case::GitVersionGuard;
use indexmap::IndexMap;
use serial_test::serial;
use shirabe::config::Config;
@@ -72,16 +73,6 @@ fn require_map(entries: &[(&str, &str)]) -> PhpMixed {
PhpMixed::Array(m)
}
-// Resets the cached git `version` static on drop so a seeded value does not leak into other
-// tests in this binary (VersionGuesserTest seeds/resets the same static).
-struct GitVersionGuard;
-
-impl Drop for GitVersionGuard {
- fn drop(&mut self) {
- GitUtil::__reset_version();
- }
-}
-
// A test double for the concrete VersionGuesser, supplied through the VersionGuesserInterface seam.
mockall::mock! {
#[derive(Debug)]
@@ -271,7 +262,6 @@ fn test_pretty_version_for_root_package_in_version_branch() {
}
#[test]
-#[ignore = "feature-branch guessing calls ProcessExecutor::execute_async, whose mock path is todo!()"]
#[serial]
fn test_feature_branch_pretty_version() {
// proc_open() is always available; the PHP markTestSkipped guard does not apply here.
diff --git a/crates/shirabe/tests/package/version/version_guesser_test.rs b/crates/shirabe/tests/package/version/version_guesser_test.rs
index 92d5e90b..dd71d8ab 100644
--- a/crates/shirabe/tests/package/version/version_guesser_test.rs
+++ b/crates/shirabe/tests/package/version/version_guesser_test.rs
@@ -185,7 +185,6 @@ fn test_guess_version_does_not_see_custom_default_branch_as_non_feature_branch()
assert_eq!(another_commit_hash, version_data.commit.unwrap());
}
-#[ignore = "feature-branch guessing calls ProcessExecutor::execute_async, whose mock path is todo!()"]
#[test]
#[serial]
fn test_guess_version_reads_and_respects_non_feature_branches_configuration_for_arbitrary_naming() {
@@ -239,7 +238,6 @@ fn test_guess_version_reads_and_respects_non_feature_branches_configuration_for_
);
}
-#[ignore = "feature-branch guessing calls ProcessExecutor::execute_async, whose mock path is todo!()"]
#[test]
#[serial]
fn test_guess_version_reads_and_respects_non_feature_branches_configuration_for_arbitrary_naming_regex()
@@ -560,7 +558,6 @@ fn test_numeric_branches_show_nicely() {
assert_eq!("1.5.9999999.9999999-dev", version_data.version.unwrap());
}
-#[ignore = "remote-branch feature guessing calls ProcessExecutor::execute_async, whose mock path is todo!()"]
#[test]
#[serial]
fn test_remote_branches_are_selected() {