Make tests assume ANDROID_ROOT is not /system.
This is to enable better chroot-like testing.
Change-Id: I943c68b0ebcdab2f107f808b466ac694085255aa
diff --git a/runtime/utils_test.cc b/runtime/utils_test.cc
index ae24b77..d8f8950 100644
--- a/runtime/utils_test.cc
+++ b/runtime/utils_test.cc
@@ -384,7 +384,8 @@
TEST_F(UtilsTest, ExecSuccess) {
std::vector<std::string> command;
if (kIsTargetBuild) {
- command.push_back("/system/bin/id");
+ std::string android_root(GetAndroidRoot());
+ command.push_back(android_root + "/bin/id");
} else {
command.push_back("/usr/bin/id");
}