Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 15f369e1 authored by Chih-Hung Hsieh's avatar Chih-Hung Hsieh
Browse files

Set rust_test modules as NATIVE_TESTS

* Rust test modules should have NATIVE_TESTS class,
  not EXECUTABLES, to work with atest --host.

Bug: 140938178
Test: make rust projects; run atest --host .
Change-Id: Ie9e237ee8c17b6e2d41f08a77c2b79d462a2c193
parent 409e833d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -89,6 +89,7 @@ func (binary *binaryDecorator) AndroidMk(ctx AndroidMkContext, ret *android.Andr

func (test *testDecorator) AndroidMk(ctx AndroidMkContext, ret *android.AndroidMkData) {
	test.binaryDecorator.AndroidMk(ctx, ret)
	ret.Class = "NATIVE_TESTS"
	stem := String(test.baseCompiler.Properties.Stem)
	if stem != "" && !strings.HasSuffix(ctx.Name(), "_"+stem) {
		// Avoid repeated suffix in the module name.