summaryrefslogtreecommitdiff
path: root/rust/test.go
diff options
context:
space:
mode:
Diffstat (limited to 'rust/test.go')
-rw-r--r--rust/test.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/rust/test.go b/rust/test.go
index 92b486070..f8ebc4c2f 100644
--- a/rust/test.go
+++ b/rust/test.go
@@ -15,6 +15,8 @@
package rust
import (
+ "github.com/google/blueprint/proptools"
+
"android/soong/android"
"android/soong/tradefed"
)
@@ -127,6 +129,9 @@ func (test *testDecorator) install(ctx ModuleContext) {
ctx.PropertyErrorf("no_named_install_directory", "Module install directory may only be disabled if relative_install_path is set")
}
+ if ctx.Host() && test.Properties.Test_options.Unit_test == nil {
+ test.Properties.Test_options.Unit_test = proptools.BoolPtr(true)
+ }
test.binaryDecorator.install(ctx)
}