diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
index e628b68..fadb76d 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
@@ -16,10 +16,18 @@
 
 package com.android.mediaframeworktest.integration;
 
+import static android.hardware.camera2.CameraDevice.TEMPLATE_PREVIEW;
+
+import static org.mockito.Mockito.any;
+import static org.mockito.Mockito.anyLong;
+import static org.mockito.Mockito.argThat;
+import static org.mockito.Mockito.spy;
+import static org.mockito.Mockito.timeout;
+import static org.mockito.Mockito.verify;
+
 import android.graphics.ImageFormat;
 import android.graphics.SurfaceTexture;
 import android.hardware.ICameraService;
-import android.hardware.camera2.CameraMetadata;
 import android.hardware.camera2.CameraCaptureSession;
 import android.hardware.camera2.CameraCharacteristics;
 import android.hardware.camera2.CaptureRequest;
@@ -41,13 +49,10 @@
 import android.util.Log;
 import android.view.Surface;
 
-import static android.hardware.camera2.CameraDevice.TEMPLATE_PREVIEW;
-
 import com.android.mediaframeworktest.MediaFrameworkIntegrationTestRunner;
 
 import org.mockito.ArgumentCaptor;
-import org.mockito.compat.ArgumentMatcher;
-import static org.mockito.Mockito.*;
+import org.mockito.ArgumentMatcher;
 
 public class CameraDeviceBinderTest extends AndroidTestCase {
     private static String TAG = "CameraDeviceBinderTest";
@@ -166,10 +171,10 @@
         }
     }
 
-    class IsMetadataNotEmpty extends ArgumentMatcher<CameraMetadataNative> {
+    class IsMetadataNotEmpty implements ArgumentMatcher<CameraMetadataNative> {
         @Override
-        public boolean matchesObject(Object obj) {
-            return !((CameraMetadataNative) obj).isEmpty();
+        public boolean matches(CameraMetadataNative obj) {
+            return !obj.isEmpty();
         }
     }
 
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/MediaInserterTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/MediaInserterTest.java
index 712039d..74bf1a2 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/MediaInserterTest.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/MediaInserterTest.java
@@ -16,13 +16,13 @@
 
 package com.android.mediaframeworktest.unit;
 
+import static org.mockito.Matchers.any;
+import static org.mockito.Matchers.argThat;
+import static org.mockito.Matchers.eq;
 import static org.mockito.Mockito.never;
 import static org.mockito.Mockito.times;
 import static org.mockito.Mockito.verify;
 import static org.mockito.Mockito.when;
-import static org.mockito.Matchers.argThat;
-import static org.mockito.Matchers.any;
-import static org.mockito.Matchers.eq;
 
 import android.content.ContentProviderClient;
 import android.content.ContentValues;
@@ -36,10 +36,9 @@
 import android.test.InstrumentationTestCase;
 import android.test.suitebuilder.annotation.SmallTest;
 
-import org.hamcrest.Description;
+import org.mockito.ArgumentMatcher;
 import org.mockito.Mock;
 import org.mockito.MockitoAnnotations;
-import org.mockito.compat.ArgumentMatcher;
 
 public class MediaInserterTest extends InstrumentationTestCase {
 
@@ -59,7 +58,7 @@
     private static final Uri sImagesUri = Images.Media.getContentUri(sVolumeName);
     private static final Uri sFilesUri = Files.getContentUri(sVolumeName);
 
-    private static class MediaUriMatcher extends ArgumentMatcher<Uri> {
+    private static class MediaUriMatcher implements ArgumentMatcher<Uri> {
         private final Uri mUri;
 
         private MediaUriMatcher(Uri uri) {
@@ -67,15 +66,8 @@
         }
 
         @Override
-        public boolean matchesObject(Object argument) {
-            if (!(argument instanceof Uri)) {
-                return false;
-            }
-
-            Uri actualUri = (Uri) argument;
-            if (actualUri == mUri)
-                return true;
-            return false;
+        public boolean matches(Uri actualUri) {
+            return actualUri == mUri;
         }
 
         @Override
diff --git a/packages/SettingsLib/tests/integ/src/com/android/settingslib/users/AppRestrictionsHelperTest.java b/packages/SettingsLib/tests/integ/src/com/android/settingslib/users/AppRestrictionsHelperTest.java
index 820231e..b011c67 100644
--- a/packages/SettingsLib/tests/integ/src/com/android/settingslib/users/AppRestrictionsHelperTest.java
+++ b/packages/SettingsLib/tests/integ/src/com/android/settingslib/users/AppRestrictionsHelperTest.java
@@ -45,9 +45,9 @@
 import android.view.inputmethod.InputMethodInfo;
 import com.android.settingslib.BaseTest;
 
+import org.mockito.ArgumentMatcher;
 import org.mockito.Mock;
 import org.mockito.MockitoAnnotations;
-import org.mockito.compat.ArgumentMatcher;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -241,7 +241,7 @@
         return ri;
     }
 
-    private class IntentMatcher extends ArgumentMatcher<Intent> {
+    private class IntentMatcher implements ArgumentMatcher<Intent> {
         private final Intent mIntent;
 
         IntentMatcher(Intent intent) {
@@ -249,11 +249,8 @@
         }
 
         @Override
-        public boolean matchesObject(Object argument) {
-            if (argument instanceof Intent) {
-                return ((Intent) argument).filterEquals(mIntent);
-            }
-            return false;
+        public boolean matches(Intent argument) {
+            return argument != null && argument.filterEquals(mIntent);
         }
 
         @Override
diff --git a/services/tests/servicestests/src/com/android/server/NetworkScorerAppManagerTest.java b/services/tests/servicestests/src/com/android/server/NetworkScorerAppManagerTest.java
index 82ff0d8..6874624 100644
--- a/services/tests/servicestests/src/com/android/server/NetworkScorerAppManagerTest.java
+++ b/services/tests/servicestests/src/com/android/server/NetworkScorerAppManagerTest.java
@@ -52,10 +52,10 @@
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
+import org.mockito.ArgumentMatcher;
 import org.mockito.Mock;
 import org.mockito.Mockito;
 import org.mockito.MockitoAnnotations;
-import org.mockito.compat.ArgumentMatcher;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -82,13 +82,9 @@
         MockitoAnnotations.initMocks(this);
         mAvailableServices = new ArrayList<>();
         when(mMockContext.getPackageManager()).thenReturn(mMockPm);
-        when(mMockPm.queryIntentServices(Mockito.argThat(new ArgumentMatcher<Intent>() {
-            @Override
-            public boolean matchesObject(Object object) {
-                Intent intent = (Intent) object;
-                return NetworkScoreManager.ACTION_RECOMMEND_NETWORKS.equals(intent.getAction());
-            }
-        }), eq(PackageManager.GET_META_DATA))).thenReturn(mAvailableServices);
+        when(mMockPm.queryIntentServices(Mockito.argThat(
+                intent -> NetworkScoreManager.ACTION_RECOMMEND_NETWORKS.equals(intent.getAction())),
+                eq(PackageManager.GET_META_DATA))).thenReturn(mAvailableServices);
         when(mMockContext.getResources()).thenReturn(mResources);
         when(mMockContext.getSystemService(Context.APP_OPS_SERVICE)).thenReturn(mAppOpsManager);
 
@@ -664,15 +660,10 @@
 
         final int flags = PackageManager.GET_META_DATA;
         when(mMockPm.resolveService(
-                Mockito.argThat(new ArgumentMatcher<Intent>() {
-                    @Override
-                    public boolean matchesObject(Object object) {
-                        Intent intent = (Intent) object;
-                        return NetworkScoreManager.ACTION_RECOMMEND_NETWORKS
-                                .equals(intent.getAction())
-                                && compName.getPackageName().equals(intent.getPackage());
-                    }
-                }), Mockito.eq(flags))).thenReturn(serviceInfo);
+                Mockito.argThat(intent -> NetworkScoreManager.ACTION_RECOMMEND_NETWORKS
+                        .equals(intent.getAction())
+                        && compName.getPackageName().equals(intent.getPackage())),
+                Mockito.eq(flags))).thenReturn(serviceInfo);
 
         mAvailableServices.add(serviceInfo);
     }
@@ -685,13 +676,9 @@
 
         final int flags = 0;
         when(mMockPm.resolveActivity(
-                Mockito.argThat(new ArgumentMatcher<Intent>() {
-                    @Override
-                    public boolean matchesObject(Object object) {
-                        Intent intent = (Intent) object;
-                        return NetworkScoreManager.ACTION_CUSTOM_ENABLE.equals(intent.getAction())
-                                && useOpenWifiComp.getPackageName().equals(intent.getPackage());
-                    }
-                }), Mockito.eq(flags))).thenReturn(resolveActivityInfo);
+                Mockito.argThat(intent ->
+                        NetworkScoreManager.ACTION_CUSTOM_ENABLE.equals(intent.getAction())
+                                && useOpenWifiComp.getPackageName().equals(intent.getPackage())),
+                Mockito.eq(flags))).thenReturn(resolveActivityInfo);
     }
 }
diff --git a/services/tests/servicestests/src/com/android/server/accessibility/MotionEventInjectorTest.java b/services/tests/servicestests/src/com/android/server/accessibility/MotionEventInjectorTest.java
index ec99a9a..fce5e3f 100644
--- a/services/tests/servicestests/src/com/android/server/accessibility/MotionEventInjectorTest.java
+++ b/services/tests/servicestests/src/com/android/server/accessibility/MotionEventInjectorTest.java
@@ -65,7 +65,6 @@
 import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.mockito.ArgumentCaptor;
-import org.mockito.compat.ArgumentMatcher;
 
 /**
  * Tests for MotionEventInjector
diff --git a/services/tests/servicestests/src/com/android/server/webkit/WebViewUpdateServiceTest.java b/services/tests/servicestests/src/com/android/server/webkit/WebViewUpdateServiceTest.java
index 05c4853..30e8449 100644
--- a/services/tests/servicestests/src/com/android/server/webkit/WebViewUpdateServiceTest.java
+++ b/services/tests/servicestests/src/com/android/server/webkit/WebViewUpdateServiceTest.java
@@ -38,9 +38,9 @@
 import org.junit.Test;
 import org.junit.runner.RunWith;
 
+import org.mockito.ArgumentMatcher;
 import org.mockito.Mockito;
 import org.mockito.Matchers;
-import org.mockito.compat.ArgumentMatcher;
 
 import java.lang.Integer;
 import java.util.concurrent.CountDownLatch;
@@ -140,7 +140,7 @@
     }
 
     // For matching the package name of a PackageInfo
-    private class IsPackageInfoWithName extends ArgumentMatcher<PackageInfo> {
+    private class IsPackageInfoWithName implements ArgumentMatcher<PackageInfo> {
         private final String mPackageName;
 
         IsPackageInfoWithName(String name) {
@@ -148,8 +148,8 @@
         }
 
         @Override
-        public boolean matchesObject(Object p) {
-            return ((PackageInfo) p).packageName.equals(mPackageName);
+        public boolean matches(PackageInfo p) {
+            return p.packageName.equals(mPackageName);
         }
 
         @Override
