am 2b0aea21: am d271d9a5: Merge change 21763 into donut

Merge commit '2b0aea21084fe303df36bcc96ed3f454c689f5aa'

* commit '2b0aea21084fe303df36bcc96ed3f454c689f5aa':
  Enable adb forwarding and starting up of monkey server
This commit is contained in:
Ramanan Rajeswaran
2009-08-18 17:20:00 -07:00
committed by Android Git Automerger

View File

@@ -45,8 +45,8 @@ import javax.imageio.ImageIO;
*/
public class MonkeyRunner {
static String monkeyServer = null;
static int monkeyPort;
static String monkeyServer = "127.0.0.1";
static int monkeyPort = 1080;
static Socket monkeySocket = null;
static IDevice monkeyDevice;
@@ -62,7 +62,7 @@ public class MonkeyRunner {
public static void main(String[] args) {
processOptions(args);
initAdbConnection();
openMonkeyConnection();
@@ -150,9 +150,13 @@ public class MonkeyRunner {
monkeyDevice = devices[0];
}
} finally {
}
monkeyDevice.createForward(monkeyPort, monkeyPort);
String command = "monkey --port " + monkeyPort;
monkeyDevice.executeShellCommand(command, new NullOutputReceiver());
} catch(IOException e) {
e.printStackTrace();
}
}
/**