cuelang.org/go@v0.10.1/internal/mod/modload/testdata/tidy/with-tools.txtar (about) 1 # Test a scenario where there are _tool.cue files, both 2 # in the main module and in the dependencies. 3 4 -- tidy-check-error -- 5 module is not tidy: missing dependency providing package test.example/foo 6 -- want -- 7 module: "main.org" 8 language: { 9 version: "v0.9.2" 10 } 11 deps: { 12 "test.example/foo@v0": { 13 v: "v0.0.1" 14 default: true 15 } 16 "test.example/toolonly@v0": { 17 v: "v0.0.1" 18 default: true 19 } 20 } 21 -- cue.mod/module.cue -- 22 module: "main.org" 23 language: { 24 version: "v0.9.2" 25 } 26 27 -- main.cue -- 28 package main 29 import "test.example/foo" 30 31 x: foo 32 33 -- main_tool.cue -- 34 package main 35 import "test.example/toolonly" 36 37 x: toolonly 38 39 -- _registry/test.example_foo_v0.0.1/cue.mod/module.cue -- 40 module: "test.example/foo" 41 language: version: "v0.10.0" 42 -- _registry/test.example_foo_v0.0.1/foo.cue -- 43 package foo 44 45 -- _registry/test.example_foo_v0.0.1/foo_tool.cue -- 46 package foo 47 48 import "test.example/nextleveltool" 49 50 x: nextleveltool 51 52 -- _registry/test.example_toolonly_v0.0.1/cue.mod/module.cue -- 53 module: "test.example/toolonly" 54 language: version: "v0.10.0" 55 56 -- _registry/test.example_toolonly_v0.0.1/x.cue -- 57 package toolonly 58 59 -- _registry/test.example_nextleveltool_v0.0.1/cue.mod/module.cue -- 60 // Note: this module should _not_ be included because it's only imported 61 // as result of the foo_tool.cue file inside the dependency test.example/foo, 62 // not from the main module. 63 64 module: "test.example/nextleveltool" 65 language: version: "v0.10.0" 66 67 -- _registry/test.example_nextleveltool_v0.0.1/x.cue -- 68 package nextleveltool