Pre-existing test failure: EquipmentNamespaceMaterializationTests deployment Rejected (not Accepted) #424
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
EquipmentNamespaceMaterializationTests.Deploying_an_equipment_namespace_carries_the_signal_into_the_artifact(inZB.MOM.WW.OtOpcUa.Host.IntegrationTests) fails:StartDeploymentAsyncreturnsStartDeploymentOutcome.Rejectedwhere the test expectsAccepted— assertion attests/Server/ZB.MOM.WW.OtOpcUa.Host.IntegrationTests/EquipmentNamespaceMaterializationTests.cs:43.The test seeds a 1-area / 1-line / 1-equipment / 1-tag Modbus equipment namespace (tag
Speed,FullName = 40001) andStartDeployments it through the realConfigComposer. The deployment is rejected at theDraftValidator/ConfigComposerstage, before the artifact is composed — so the downstreamParseCompositionassertions are never reached.Repro
Result:
Pre-existing / scope
DraftValidator/ConfigComposer/ equipment-namespace-materialization code path (git diff --stat master..HEADconfirms only*Historian*files changed), yet the test fails identically.Next step
Root-cause the
DraftValidatorrejection of the Modbus-only namespace (the deployment is rejected before composition). Most likely a validation rule or environment/config expectation the seeded namespace no longer satisfies — capture the rejection reason from theStartDeploymentoutcome / validator diagnostics.Resolved by
859d6317("fix(harness): make deploy E2E tests pass against real SQL (seed cluster FKs)", 2026-07-15, inmaster).Root cause
Not a
DraftValidatorrule regression — the rejection was a missing FK-parent seed on real SQL. The test seeded the equipment namespace but not the parentServerCluster/ClusterNoderows the SQL FKs require. On the in-memory provider FKs aren't enforced, so it "passed" there; against real SQLStartDeploymentwas rejected before composition. This is the same class of false alarm the 2026-07-15 integration sweep catalogued (#6b: in-memory-hidden FK-parent-seed + stale-EquipmentId), not asp_ValidateDraft/managed-validator defect.Fix
The test now calls
harness.SeedDefaultClusterAsync("c1")beforeSeedEquipmentNamespaceAsync(seeEquipmentNamespaceMaterializationTests.cs:46), seeding the parent cluster/node FK rows.Verification
dotnet test --filter FullyQualifiedName~EquipmentNamespaceMaterializationTests→ Passed 3/3 consecutive runs onmaster@e0ff908d. Closing as resolved.