Files
Krishnan K M 334e41060f Fix: expand dotted field paths in ItemBuilder.Set (#7302)
* fix: expand dotted field paths in ItemBuilder.Set

Signed-off-by: Krishnan K M <krishnankaruvattu@gmail.com>

* Fix: preserve dots in bracketed SetIf paths

Signed-off-by: Krishnan K M <krishnankaruvattu@gmail.com>

---------

Signed-off-by: Krishnan K M <krishnankaruvattu@gmail.com>
2026-08-13 11:33:04 +01:00

39 lines
1.0 KiB
Go

/*
Copyright 2025 The KubeVela Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package defkit_test
import (
"testing"
"cuelang.org/go/cue/parser"
. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
)
func TestDefkit(t *testing.T) {
RegisterFailHandler(Fail)
RunSpecs(t, "Defkit Suite")
}
// parseCUE parses generated CUE and returns any syntax error. Substring
// assertions cannot tell a well-formed definition from one that only breaks
// once a parser reaches it.
func parseCUE(src string) error {
_, err := parser.ParseFile("generated.cue", src)
return err
}