Skip to content

Commit 20d3c9c

Browse files
committed
cmd/cue: speed up get_go_json_compat.txtar
We only need to `cue get go` the decls package, and not the marshal and unmarshal packages which we only use for `go run`. This results in less work to load Go packages in `cue get go`, speeding up the test on my laptop from 0.50s to 0.42s. Signed-off-by: Daniel Martí <[email protected]> Change-Id: I207aea043edf8070a4a9e29308103d6a46654a09 Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1198963 Reviewed-by: Roger Peppe <[email protected]> TryBot-Result: CUEcueckoo <[email protected]> Unity-Result: CUE porcuepine <[email protected]>
1 parent 3260084 commit 20d3c9c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd/cue/cmd/testdata/script/get_go_json_compat.txtar

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Check that the CUE generated by 'cue get go' is actually compatible
22
# with encoding and decoding values via Go's encoding/json package.
33

4-
exec cue get go --local ./...
4+
exec cue get go --local ./decls
55
cmp decls/p_go_gen.cue decls/p_go_gen.cue.golden
66

77
# Marshal via Go's encoding/json and validate with the generated CUE schema.

0 commit comments

Comments
 (0)