Skip to content

Commit f7f3c39

Browse files
[minor] test fixup
1 parent 68a141c commit f7f3c39

File tree

1 file changed

+14
-10
lines changed

1 file changed

+14
-10
lines changed

nexus/tests/integration_tests/multicast/failures.rs

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ async fn test_multicast_reconciler_state_consistency_validation(
182182
});
183183
ops::join_all(create_futures).await;
184184

185-
// Stop DPD before attaching members to test failure recovery
185+
// Stop DPD before attaching members to test state consistency during failure
186186
// Groups will be implicitly created but stay in "Creating" state
187187
cptestctx.stop_dendrite(SwitchLocation::Switch0).await;
188188

@@ -229,23 +229,27 @@ async fn test_multicast_reconciler_state_consistency_validation(
229229
);
230230
}
231231

232+
// Verify groups are still stuck in expected states before restarting DPD
233+
// This explicitly validates that without DPD, groups cannot transition
234+
for group_name in group_names.iter() {
235+
verify_group_deleted_or_in_states(client, group_name, &["Creating"])
236+
.await;
237+
}
238+
239+
// Restart DPD before cleanup so instances can stop properly
240+
cptestctx.restart_dendrite(SwitchLocation::Switch0).await;
241+
232242
let instance_name_refs: Vec<&str> =
233243
instance_names.iter().map(|s| s.as_str()).collect();
234244
cleanup_instances(cptestctx, client, project_name, &instance_name_refs)
235245
.await;
236246

237-
// With DPD down, groups cannot complete state transitions - they may be stuck
238-
// in "Creating" (never reached "Active") or "Deleting" state.
247+
// With DPD now restored, groups should be cleaned up via implicit deletion
239248
wait_for_multicast_reconciler(&cptestctx.lockstep_client).await;
240249

241-
// Verify groups are either deleted or stuck in "Creating"/"Deleting" state
250+
// Verify groups are deleted (implicit deletion completes with DPD available)
242251
for group_name in group_names.iter() {
243-
verify_group_deleted_or_in_states(
244-
client,
245-
group_name,
246-
&["Creating", "Deleting"],
247-
)
248-
.await;
252+
wait_for_group_deleted(client, group_name).await;
249253
}
250254
}
251255

0 commit comments

Comments
 (0)