Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c189e7b8ab | ||
|
|
d0833ad563 |
No files matched your search
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [0.1.3](https://codeberg.org/wvhulle/bootvine/compare/v0.1.2...v0.1.3) - 2026-11-02
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- do not report collected systemd jobs as failed
|
||||||
|
|
||||||
## [0.1.2](https://codeberg.org/wvhulle/bootvine/compare/v0.1.1...v0.1.2) - 2026-11-02
|
## [0.1.2](https://codeberg.org/wvhulle/bootvine/compare/v0.1.1...v0.1.2) - 2026-11-02
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
Generated
+1
-1
@@ -144,7 +144,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "bootvine"
|
name = "bootvine"
|
||||||
version = "0.1.2"
|
version = "0.1.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"clap",
|
"clap",
|
||||||
"crossterm 0.29.0",
|
"crossterm 0.29.0",
|
||||||
|
|||||||
+1
-1
@@ -9,7 +9,7 @@ name = "bootvine"
|
|||||||
readme = "../README.md"
|
readme = "../README.md"
|
||||||
repository = "https://codeberg.org/wvhulle/bootvine"
|
repository = "https://codeberg.org/wvhulle/bootvine"
|
||||||
rust-version = "1.91"
|
rust-version = "1.91"
|
||||||
version = "0.1.2"
|
version = "0.1.3"
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|||||||
@@ -194,7 +194,7 @@ impl BootState {
|
|||||||
};
|
};
|
||||||
let outcome = match result {
|
let outcome = match result {
|
||||||
JobResult::Done => Outcome::Succeeded { at },
|
JobResult::Done => Outcome::Succeeded { at },
|
||||||
JobResult::Skipped | JobResult::Canceled => Outcome::Abandoned,
|
JobResult::Skipped | JobResult::Canceled | JobResult::Collected => Outcome::Abandoned,
|
||||||
JobResult::Failed => Outcome::Failed(FailureKind::Broke),
|
JobResult::Failed => Outcome::Failed(FailureKind::Broke),
|
||||||
JobResult::Timeout => Outcome::Failed(FailureKind::TimedOut),
|
JobResult::Timeout => Outcome::Failed(FailureKind::TimedOut),
|
||||||
JobResult::Dependency => Outcome::Failed(FailureKind::DependencyFailed),
|
JobResult::Dependency => Outcome::Failed(FailureKind::DependencyFailed),
|
||||||
@@ -337,6 +337,20 @@ mod tests {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn a_collected_job_on_a_multi_device_mount_source_is_not_a_failure() {
|
||||||
|
let mut state = BootState::new(Phase::Initrd);
|
||||||
|
queue_unit(
|
||||||
|
&mut state,
|
||||||
|
1,
|
||||||
|
waiting("dev-nvme0n1p1:-dev-nvme1n1p3.device", &[]),
|
||||||
|
500 * MS,
|
||||||
|
);
|
||||||
|
state.finish_job(1, JobResult::Collected, 2000 * MS);
|
||||||
|
assert!(state.failed.is_empty());
|
||||||
|
assert_eq!(state.tally().failed, 0);
|
||||||
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn a_unit_entering_the_failed_state_counts_without_a_failed_job() {
|
fn a_unit_entering_the_failed_state_counts_without_a_failed_job() {
|
||||||
let mut state = sample();
|
let mut state = sample();
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ pub enum JobResult {
|
|||||||
Done,
|
Done,
|
||||||
Skipped,
|
Skipped,
|
||||||
Canceled,
|
Canceled,
|
||||||
|
Collected,
|
||||||
Timeout,
|
Timeout,
|
||||||
Dependency,
|
Dependency,
|
||||||
#[serde(other)]
|
#[serde(other)]
|
||||||
@@ -162,6 +163,7 @@ mod tests {
|
|||||||
);
|
);
|
||||||
assert_eq!(from_str("maintenance").ok(), Some(ActiveState::Inactive));
|
assert_eq!(from_str("maintenance").ok(), Some(ActiveState::Inactive));
|
||||||
assert_eq!(from_str("dependency").ok(), Some(JobResult::Dependency));
|
assert_eq!(from_str("dependency").ok(), Some(JobResult::Dependency));
|
||||||
|
assert_eq!(from_str("collected").ok(), Some(JobResult::Collected));
|
||||||
assert_eq!(from_str("frozen").ok(), Some(JobResult::Failed));
|
assert_eq!(from_str("frozen").ok(), Some(JobResult::Failed));
|
||||||
assert_eq!(from_str("stop").ok(), Some(JobKind::TakesDown));
|
assert_eq!(from_str("stop").ok(), Some(JobKind::TakesDown));
|
||||||
assert_eq!(from_str("restart").ok(), Some(JobKind::BringsUp));
|
assert_eq!(from_str("restart").ok(), Some(JobKind::BringsUp));
|
||||||
|
|||||||
Reference in new issue
Block a user