From a62a611a831f30b4d44392a0ac8bf2c0ef5a8e7c Mon Sep 17 00:00:00 2001 From: Roshan Pius Date: Fri, 18 Oct 2019 06:29:14 -0700 Subject: WifiStack: Copy over runWithScissors method Handler.runWithScissors is a simple @hide utility in Handler that should never become part of the formal Android API surface. Copy over the method to wifi. Bug: 142809066 Test: atest com.android.server.wifi.util Change-Id: I675121bb5b4e65e0a0a3db0b9ebee7277817d7c6 --- tests/wifitests/src/com/android/server/wifi/WifiThreadRunnerTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/wifitests/src/com/android/server/wifi/WifiThreadRunnerTest.java b/tests/wifitests/src/com/android/server/wifi/WifiThreadRunnerTest.java index 7a051e2a8..59f2ed817 100644 --- a/tests/wifitests/src/com/android/server/wifi/WifiThreadRunnerTest.java +++ b/tests/wifitests/src/com/android/server/wifi/WifiThreadRunnerTest.java @@ -85,7 +85,7 @@ public class WifiThreadRunnerTest { @Test public void callFailure_returnValueOnTimeout() { - doReturn(false).when(mHandler).runWithScissors(any(), anyLong()); + doReturn(false).when(mHandler).post(any()); Integer result = mWifiThreadRunner.call(mSupplier, VALUE_ON_TIMEOUT); @@ -110,7 +110,7 @@ public class WifiThreadRunnerTest { @Test public void runFailure() { - doReturn(false).when(mHandler).runWithScissors(any(), anyLong()); + doReturn(false).when(mHandler).post(any()); boolean runSuccess = mWifiThreadRunner.run(mRunnable); -- cgit v1.2.3