From c58f516a6bb1e97d4423620f9d7ca0ab5f0af8b0 Mon Sep 17 00:00:00 2001 From: Narayan Kamath Date: Thu, 24 Oct 2013 14:56:38 +0100 Subject: Delete some pointless and invalid code. These "convenience" methods are invalid because they all have the same erasure. They do not compile with java-7-openjdk. android-mock is used only by QuicksearchBoxGoogle (which I'm going to remove soon) and no new projects should use it. (They should use mockito instead) bug: 8992787 (cherry picked from commit 41cc67f9282657bfcf6ed2b565ee42ed7a40ee6c) Change-Id: I31dd6741037a73ff005d90b3a1e43eafa3e93558 --- .../android/testing/mocking/AndroidMock.java | 90 ---------------------- 1 file changed, 90 deletions(-) diff --git a/src/com/google/android/testing/mocking/AndroidMock.java b/src/com/google/android/testing/mocking/AndroidMock.java index 88f79b1..8378c4e 100644 --- a/src/com/google/android/testing/mocking/AndroidMock.java +++ b/src/com/google/android/testing/mocking/AndroidMock.java @@ -2360,96 +2360,6 @@ public class AndroidMock { return EasyMock.capture(captured); } - /** - * Expect any {@code int/Integer} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0}. The return value is always ignored. - */ - public static int capture(Capture captured) { - return EasyMock.capture(captured); - } - - /** - * Expect any {@code long/Long} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0}. The return value is always ignored. - */ - public static long capture(Capture captured) { - return EasyMock.capture(captured); - } - - /** - * Expect any {@code float/Float} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0}. The return value is always ignored. - */ - public static float capture(Capture captured) { - return EasyMock.capture(captured); - } - - /** - * Expect any {@code double/Double} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0}. The return value is always ignored. - */ - public static double capture(Capture captured) { - return EasyMock.capture(captured); - } - - /** - * Expect any {@code byte/Byte} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0} - */ - public static byte capture(Capture captured) { - return EasyMock.capture(captured); - } - - /** - * Expect any {@code char/Character} as a parameter to the mocked method, but capture it for later - * use. - * - * {@link org.easymock.Capture} allows for capturing of the incoming value. Use - * {@link org.easymock.Capture#getValue()} to retrieve the captured value. - * - * @param captured a container to hold the captured value, retrieved by - * {@link org.easymock.Capture#getValue()} - * @return {@code 0} - */ - public static char capture(Capture captured) { - return EasyMock.capture(captured); - } - /** * Switches the given mock objects (more exactly: the controls of the mock * objects) to replay mode. -- cgit v1.2.3