Skip to content

x/build/cmd/golangbuild: also move or delete untested nested modules for run-tests-outside-repository check #65267

Closed
@dmitshur

Description

@dmitshur

One of the items implemented in #60666 was:

  • run subrepo tests from outside their repositories (equivalent to x/build/cmd/coordinator's go.dev/issue/34352)

The repoToModules function is responsible for finding modules in repoDir to be tested, and for repos without local replace directives, it also moves nested modules to directories that aren't predictably-relative to each other.

It's right for repoToModules to skip over directories that aren't intended to have testable modules (for example, directories with "." or "_" prefixes, or named "testdata"), but they should still be visited for the purpose of moving them to an unpredictable location (or, removing them entirely, since their content isn't needed for running tests).

Filing this to track that fix. When rolling it out, it's worth paying attention to how many newly failing tests it begins to catch, and to give them an opportunity to be fixed or otherwise handled without undue time pressure.

Metadata

Metadata

Assignees

Labels

Buildersx/build issues (builders, bots, dashboards)NeedsFixThe path to resolution is known, but the work has not been done.

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions