(t *testing.T)
| 1202 | } |
| 1203 | |
| 1204 | func TestWorkspaceOverlappingModuleDirPaths(t *testing.T) { |
| 1205 | t.Parallel() |
| 1206 | workspaceDir := filepath.Join("testdata", "workspace", "success", "overlapping_dir_path") |
| 1207 | requireBuildOutputFilePaths( |
| 1208 | t, |
| 1209 | map[string]expectedFileInfo{ |
| 1210 | "foo/foo.proto": {moduleFullName: "buf.test/acme/foobar"}, |
| 1211 | "bar/bar.proto": {moduleFullName: "buf.test/acme/foobar"}, |
| 1212 | "foo_internal.proto": {}, |
| 1213 | "bar_internal.proto": {}, |
| 1214 | }, |
| 1215 | workspaceDir, |
| 1216 | ) |
| 1217 | requireBuildOutputFilePaths( |
| 1218 | t, |
| 1219 | map[string]expectedFileInfo{ |
| 1220 | "foo_internal.proto": {}, |
| 1221 | }, |
| 1222 | workspaceDir, |
| 1223 | "--path", |
| 1224 | filepath.Join(workspaceDir, "proto", "foo", "internal", "foo_internal.proto"), |
| 1225 | ) |
| 1226 | requireBuildOutputFilePaths( |
| 1227 | t, |
| 1228 | map[string]expectedFileInfo{ |
| 1229 | "foo/foo.proto": {moduleFullName: "buf.test/acme/foobar"}, |
| 1230 | "bar/bar.proto": {moduleFullName: "buf.test/acme/foobar"}, |
| 1231 | }, |
| 1232 | workspaceDir, |
| 1233 | "--exclude-path", |
| 1234 | filepath.Join(workspaceDir, "proto", "foo", "internal", "foo_internal.proto"), |
| 1235 | "--exclude-path", |
| 1236 | filepath.Join(workspaceDir, "proto", "bar", "internal", "bar_internal.proto"), |
| 1237 | ) |
| 1238 | } |
| 1239 | |
| 1240 | func TestWorkspaceDuplicateFail(t *testing.T) { |
| 1241 | t.Parallel() |
nothing calls this directly
no test coverage detected
searching dependent graphs…