|
285 | 285 | Run("SIGTRAN commercial evidence execution artifact manifest covers retained outputs", SigtranCommercialEvidenceExecutionArtifactManifestCoversRetainedOutputs); |
286 | 286 | Run("SIGTRAN commercial evidence execution verification requires digests and redaction", SigtranCommercialEvidenceExecutionVerificationRequiresDigestsAndRedaction); |
287 | 287 | Run("SIGTRAN commercial evidence execution blocker classifier categorizes failures", SigtranCommercialEvidenceExecutionBlockerClassifierCategorizesFailures); |
| 288 | +Run("SIGTRAN commercial evidence execution retry policy gates resume decisions", SigtranCommercialEvidenceExecutionRetryPolicyGatesResumeDecisions); |
288 | 289 | Run("SIGTRAN status capabilities use domain documentation labels", SigtranStatusCapabilitiesUseDomainDocumentationLabels); |
289 | 290 | Run("Native SCTP platform probe reports socket creation capability", NativeSctpPlatformProbeReportsSocketCreationCapability); |
290 | 291 | Run("Native SCTP socket factory creates or reports unsupported platform", NativeSctpSocketFactoryCreatesOrReportsUnsupportedPlatform); |
@@ -4733,6 +4734,35 @@ static void SigtranCommercialEvidenceExecutionBlockerClassifierCategorizesFailur |
4733 | 4734 | Assert(!unknown.Retryable, "unknown blocker should not be automatically retried"); |
4734 | 4735 | } |
4735 | 4736 |
|
| 4737 | +static void SigtranCommercialEvidenceExecutionRetryPolicyGatesResumeDecisions() |
| 4738 | +{ |
| 4739 | + SigtranCommercialEvidenceExecutionRun run = SigtranCommercialEvidenceExecutionRuns.CreateReleaseCandidateRun( |
| 4740 | + "1.0.0-rc.1", |
| 4741 | + "abcdef123456", |
| 4742 | + "run-20260622-001", |
| 4743 | + "release-automation", |
| 4744 | + DateTimeOffset.UtcNow); |
| 4745 | + SigtranCommercialEvidenceExecutionStageCatalog catalog = SigtranCommercialEvidenceExecutionStages.CreateDefault(run); |
| 4746 | + SigtranCommercialEvidenceExecutionRetryPolicy policy = SigtranCommercialEvidenceExecutionRetryPolicies.CreateDefault(catalog); |
| 4747 | + SigtranCommercialEvidenceExecutionBlockerClassifier classifier = SigtranCommercialEvidenceExecutionBlockers.CreateDefault(); |
| 4748 | + SigtranCommercialEvidenceExecutionRetryDecision peerRetry = policy.Decide(classifier.Classify("external-peer-unavailable"), attemptCount: 1); |
| 4749 | + SigtranCommercialEvidenceExecutionRetryDecision peerExhausted = policy.Decide(classifier.Classify("external-peer-unavailable"), attemptCount: 3); |
| 4750 | + SigtranCommercialEvidenceExecutionRetryDecision nativeSctp = policy.Decide(classifier.Classify("native-sctp-unavailable"), attemptCount: 0); |
| 4751 | + SigtranCommercialEvidenceExecutionRetryDecision unknown = policy.Decide(classifier.Classify("operator-note-required"), attemptCount: 0); |
| 4752 | + |
| 4753 | + Assert(policy.IsReady, policy.Describe()); |
| 4754 | + Assert(policy.CoversKnownBlockers, "retry policy should cover known blocker kinds"); |
| 4755 | + Assert(policy.UsesKnownResumeStages, "retry policy should resume from known stages"); |
| 4756 | + Assert(policy.ProtectsNonRetryableFailures, "retry policy should protect non-retryable failures"); |
| 4757 | + Assert(peerRetry.CanRetry, "external peer blocker should be retryable before exhaustion"); |
| 4758 | + Assert(peerRetry.ResumeStageId == "external-peer-interop", "external peer retry should resume from peer stage"); |
| 4759 | + Assert(!peerExhausted.CanRetry, "external peer retry should stop after max attempts"); |
| 4760 | + Assert(peerExhausted.RequiresManualCorrection, "exhausted retry should require manual correction"); |
| 4761 | + Assert(!nativeSctp.CanRetry, "native SCTP host blocker should not retry automatically"); |
| 4762 | + Assert(nativeSctp.RequiresManualCorrection, "native SCTP blocker should require host correction"); |
| 4763 | + Assert(!unknown.CanRetry, "unknown blockers should not retry automatically"); |
| 4764 | +} |
| 4765 | + |
4736 | 4766 | static void SigtranStatusCapabilitiesUseDomainDocumentationLabels() |
4737 | 4767 | { |
4738 | 4768 | IReadOnlyList<string>[] statusCapabilities = |
|
0 commit comments