Check source versions against original document controls

This commit is contained in:
2026-11-02 00:37:45 +00:00
parent 1fd0adc571
commit ad5b859337
5 changed files with 102 additions and 46 deletions

View File

@@ -126,13 +126,13 @@ func TestParseSequenceDeclarationRejectsMalformedForms(t *testing.T) {
}
func TestSequenceDeclarationsDoNotTriggerVersionOverlapWhenHeaderIsAbsent(t *testing.T) {
root := parseRootDirectiveDocument(t, `configkit:
root := parseRootDirectiveDocument(t, `config:
sequences:
- destination: [prompts]
key: id
version: v1
`)
presentPath, err := ParsePath("/configkit/sequences/0/destination")
presentPath, err := ParsePath("/config/sequences/0/destination")
if err != nil {
t.Fatal(err)
}
@@ -140,7 +140,7 @@ version: v1
if !sourceVersionHeaderControlOverlap(root, present) {
t.Fatal("present version header beneath a sequence control did not overlap")
}
absentPath, err := ParsePath("/configkit/sequences/1/destination")
absentPath, err := ParsePath("/config/sequences/1/destination")
if err != nil {
t.Fatal(err)
}