summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Geoffray <ngeoffray@google.com>2015-04-24 12:45:54 +0100
committerNicolas Geoffray <ngeoffray@google.com>2015-04-24 12:45:54 +0100
commit54d3b9369fe3d02ce573acdc703b694e7292704e (patch)
tree65316cf453bbc425b730e7803432bce2a3a64b7f
parent73e9c6e19e1ffcf00cf55fc1529f9c6c1e8a3bdf (diff)
downloadlibcore-54d3b9369fe3d02ce573acdc703b694e7292704e.zip
libcore-54d3b9369fe3d02ce573acdc703b694e7292704e.tar.gz
libcore-54d3b9369fe3d02ce573acdc703b694e7292704e.tar.bz2
Use ANDROID_ROOT instead of assuming it is /system.
This is to allow testing without having 'sh', or having an outdated 'sh' in /system. Change-Id: I19f2844822cc282c4e7696d45fb5ccbe1a1710eb
-rw-r--r--luni/src/test/java/libcore/java/lang/ProcessBuilderTest.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/luni/src/test/java/libcore/java/lang/ProcessBuilderTest.java b/luni/src/test/java/libcore/java/lang/ProcessBuilderTest.java
index 9766cef..51aed38 100644
--- a/luni/src/test/java/libcore/java/lang/ProcessBuilderTest.java
+++ b/luni/src/test/java/libcore/java/lang/ProcessBuilderTest.java
@@ -28,7 +28,7 @@ import static tests.support.Support_Exec.execAndCheckOutput;
public class ProcessBuilderTest extends AbstractResourceLeakageDetectorTestCase {
private static String shell() {
- String deviceSh = "/system/bin/sh";
+ String deviceSh = System.getenv("ANDROID_ROOT") + "/bin/sh";
String desktopSh = "/bin/sh";
return new File(deviceSh).exists() ? deviceSh : desktopSh;
}