diff options
| author | 2023-11-21 09:17:11 +0000 | |
|---|---|---|
| committer | 2023-11-21 09:17:11 +0000 | |
| commit | bc34d495c922c8156337466a1327f4bc615a9696 (patch) | |
| tree | 9e37304470013eb9435f609e99eaefb4be8a7339 /rust/rust.go | |
| parent | 3f7d0f6797159afe5ea61fb489ec9a582811d970 (diff) | |
| parent | 87b2ab28a80c11b264794344c4299e734b87e24d (diff) | |
Merge "Add test spec provider to test modules." into main
Diffstat (limited to 'rust/rust.go')
| -rw-r--r-- | rust/rust.go | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/rust/rust.go b/rust/rust.go index 19c5230b4..15144acad 100644 --- a/rust/rust.go +++ b/rust/rust.go @@ -20,6 +20,7 @@ import ( "android/soong/bazel" "android/soong/bloaty" + "android/soong/testing" "android/soong/ui/metrics/bp2build_metrics_proto" "github.com/google/blueprint" @@ -144,8 +145,9 @@ type Module struct { Properties BaseProperties - hod android.HostOrDeviceSupported - multilib android.Multilib + hod android.HostOrDeviceSupported + multilib android.Multilib + testModule bool makeLinkType string @@ -1038,6 +1040,9 @@ func (mod *Module) GenerateAndroidBuildActions(actx android.ModuleContext) { ctx.Phony("rust", ctx.RustModule().OutputFile().Path()) } + if mod.testModule { + ctx.SetProvider(testing.TestModuleProviderKey, testing.TestModuleProviderData{}) + } } func (mod *Module) deps(ctx DepsContext) Deps { |