misc/android: go_android_exec fails to copy other package sources in the main module when executing tests #37088
Labels
help wanted
mobile
Android, iOS, and x/mobile
NeedsFix
The path to resolution is known, but the work has not been done.
Milestone
In order to ensure that a test binary can find any associated test data,
go test
runs the resulting test binary in its own source directory.That implies that, if a
go
binary is present, the test cango build
both files in its own directory and any associated packages in the same module.Unfortunately,
adbCopyTree
function ingo_android_exec.go
does not ensure that the source code for the complete module is present. Instead, it copies only thego.mod
andgo.sum
files andtestdata
directories going up the tree.That implies that
go_android_exec
cannot successfully execute an external test that runs an associatedmain
package as a subprocess if thatmain
package imports any other package outside of the standard library, such as in CL 218277.CC @hajimehoshi @hyangah @steeve @eliasnaur
The text was updated successfully, but these errors were encountered: