Index: mojo/android/javatests/src/org/chromium/mojo/system/impl/WatcherImplTest.java |
diff --git a/mojo/android/javatests/src/org/chromium/mojo/system/impl/WatcherImplTest.java b/mojo/android/javatests/src/org/chromium/mojo/system/impl/WatcherImplTest.java |
index e14adb1160a9b580ba80d253785480063918689e..6a99fe155f47e0e5b1f52403d04275d183a85405 100644 |
--- a/mojo/android/javatests/src/org/chromium/mojo/system/impl/WatcherImplTest.java |
+++ b/mojo/android/javatests/src/org/chromium/mojo/system/impl/WatcherImplTest.java |
@@ -68,17 +68,6 @@ |
private static class WatcherResult implements Callback { |
private int mResult = Integer.MIN_VALUE; |
- private MessagePipeHandle mReadPipe; |
- |
- /** |
- * @param readPipe A MessagePipeHandle to read from when onResult triggers success. |
- */ |
- public WatcherResult(MessagePipeHandle readPipe) { |
- mReadPipe = readPipe; |
- } |
- public WatcherResult() { |
- this(null); |
- } |
/** |
* @see Callback#onResult(int) |
@@ -86,11 +75,6 @@ |
@Override |
public void onResult(int result) { |
this.mResult = result; |
- |
- if (result == MojoResult.OK && mReadPipe != null) { |
- mReadPipe.readMessage( |
- null, 0, MessagePipeHandle.ReadFlags.none().setMayDiscard(true)); |
- } |
} |
/** |
@@ -109,7 +93,7 @@ |
// Checking a correct result. |
Pair<MessagePipeHandle, MessagePipeHandle> handles = mCore.createMessagePipe(null); |
addHandlePairToClose(handles); |
- final WatcherResult watcherResult = new WatcherResult(handles.first); |
+ final WatcherResult watcherResult = new WatcherResult(); |
assertEquals(Integer.MIN_VALUE, watcherResult.getResult()); |
mWatcher.start(handles.first, Core.HandleSignals.READABLE, watcherResult); |