Own the patched runsc artifact and bind recovery identity
This commit is contained in:
parent
c474fa4a23
commit
2c420012bd
2 changed files with 1967 additions and 130 deletions
|
|
@ -129,6 +129,7 @@ fn every_schema_shape_round_trips_and_rejects_malformed_or_unknown_versions() {
|
|||
PersistedHostProcessOwnership::staged(pidfs_identity),
|
||||
&mut seen,
|
||||
);
|
||||
verify_shape(RunscProcessOwnership::Staged(pidfs_identity), &mut seen);
|
||||
verify_shape(
|
||||
HostProcessOwnershipSlot::SessionTerminalExecClient(session_id()),
|
||||
&mut seen,
|
||||
|
|
@ -425,7 +426,13 @@ fn every_schema_shape_round_trips_and_rejects_malformed_or_unknown_versions() {
|
|||
bundle_digest: Some(BundleDigest::new(opaque(66))),
|
||||
host_coordinator: owned_process(30),
|
||||
runtime_supervisor: owned_process(21),
|
||||
attached_runsc: owned_process(67),
|
||||
attached_runsc: PersistedHostProcessOwnership::Runsc {
|
||||
build_id: RunscBuildId::new(opaque(67)),
|
||||
digest: RunscDigest::new(opaque(71)),
|
||||
process: RunscProcessOwnership::Committed(HostProcessIdentity::pidfs_v1(process(
|
||||
67,
|
||||
))),
|
||||
},
|
||||
},
|
||||
&mut seen,
|
||||
);
|
||||
|
|
@ -642,8 +649,8 @@ persistent_dirs = []
|
|||
assert_eq!(
|
||||
seen.digest(),
|
||||
[
|
||||
23, 80, 80, 177, 148, 141, 234, 213, 240, 108, 167, 148, 252, 121, 212, 128, 5, 195,
|
||||
176, 126, 71, 76, 141, 196, 174, 125, 212, 31, 115, 155, 178, 139,
|
||||
54, 187, 13, 149, 227, 157, 1, 54, 234, 66, 127, 9, 34, 65, 173, 20, 214, 200, 126, 67,
|
||||
1, 216, 152, 76, 167, 32, 177, 218, 0, 192, 175, 28,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,6 +52,17 @@ fn lifecycle_corpus(digest: &mut Sha256) {
|
|||
PersistedHostProcessOwnership::Unassigned => PersistedHostProcessOwnership::unassigned(),
|
||||
PersistedHostProcessOwnership::Staged(_) => PersistedHostProcessOwnership::staged(process(1)),
|
||||
PersistedHostProcessOwnership::Committed(_) => PersistedHostProcessOwnership::committed(process(2)),
|
||||
PersistedHostProcessOwnership::Runsc { .. } => PersistedHostProcessOwnership::runsc_unassigned(
|
||||
RunscBuildId::new(opaque(3)),
|
||||
RunscDigest::new(opaque(4)),
|
||||
),
|
||||
});
|
||||
enum_corpus!(digest, RunscProcessOwnership, {
|
||||
RunscProcessOwnership::Unassigned => RunscProcessOwnership::Unassigned,
|
||||
RunscProcessOwnership::Staged(_) => RunscProcessOwnership::Staged(process(5)),
|
||||
RunscProcessOwnership::Committed(_) => RunscProcessOwnership::Committed(
|
||||
HostProcessIdentity::pidfs_v1(process(6)),
|
||||
),
|
||||
});
|
||||
enum_corpus!(digest, ProcessOwnershipMessageVersion, {
|
||||
ProcessOwnershipMessageVersion::V1 => ProcessOwnershipMessageVersion::V1,
|
||||
|
|
@ -314,8 +325,8 @@ fn every_serialized_enum_variant_has_fixed_shape_evidence() {
|
|||
assert_eq!(
|
||||
digest.finalize().as_slice(),
|
||||
[
|
||||
199, 150, 218, 48, 172, 14, 153, 234, 245, 198, 178, 249, 47, 35, 217, 83, 28, 188,
|
||||
123, 152, 3, 15, 150, 61, 79, 255, 244, 107, 132, 27, 167, 123,
|
||||
63, 126, 242, 211, 164, 165, 11, 185, 180, 135, 109, 135, 92, 142, 111, 169, 142, 215,
|
||||
49, 4, 170, 169, 119, 237, 235, 161, 192, 89, 92, 93, 88, 35,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue