Skip to content

Commit

Permalink
prepare tags test
Browse files Browse the repository at this point in the history
  • Loading branch information
yujinyan committed Jul 10, 2021
1 parent 0eec21e commit 92ddb7c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion cue_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,11 @@ func TestInstance(t *testing.T) {
log.Println(instance)
}

func TestGetTags(t *testing.T) {
// todo
// see cue/load/tags.go
}

func p(v interface{}) {
log.Printf("value is %v\n", v)
}
Expand Down Expand Up @@ -225,7 +230,7 @@ func getInstance(dir string, root string) (*cue.Value, error) {
}
instance := instances[0]

//instance.AllTags
log.Printf("tags are %v", instance.AllTags)

var value cue.Value
if v := ctx.BuildInstance(instance); v.Err() == nil {
Expand Down
2 changes: 1 addition & 1 deletion sample/namespace.cue
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
package cluster

#namespace: "default"
#namespace: string @tag(namespace)

0 comments on commit 92ddb7c

Please sign in to comment.