Home
last modified time | relevance | path

Searched refs:matches (Results 1 – 25 of 187) sorted by relevance

12345678

/packages/apps/Launcher3/tests/src/com/android/launcher3/allapps/search/
DDefaultAppSearchAlgorithmTest.java42 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("white cow"), "cow", MATCHER)); in testMatches()
43 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("whiteCow"), "cow", MATCHER)); in testMatches()
44 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("whiteCOW"), "cow", MATCHER)); in testMatches()
45 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("whitecowCOW"), "cow", MATCHER)); in testMatches()
46 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("white2cow"), "cow", MATCHER)); in testMatches()
48 assertFalse(DefaultAppSearchAlgorithm.matches(getInfo("whitecow"), "cow", MATCHER)); in testMatches()
49 assertFalse(DefaultAppSearchAlgorithm.matches(getInfo("whitEcow"), "cow", MATCHER)); in testMatches()
51 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("whitecowCow"), "cow", MATCHER)); in testMatches()
52 assertTrue(DefaultAppSearchAlgorithm.matches(getInfo("whitecow cow"), "cow", MATCHER)); in testMatches()
53 assertFalse(DefaultAppSearchAlgorithm.matches(getInfo("whitecowcow"), "cow", MATCHER)); in testMatches()
[all …]
/packages/apps/UnifiedEmail/src/com/google/android/mail/common/base/
DCharMatcher.java132 @Override public boolean matches(char c) {
144 @Override public boolean matches(char c) {
154 @Override public boolean matches(char c) {
164 @Override public boolean matches(char c) {
174 @Override public boolean matches(char c) {
243 @Override public boolean matches(char c) {
310 @Override public boolean matches(char c) {
381 @Override public boolean matches(char c) { in is()
390 return other.matches(match) ? this : NONE; in is()
393 return other.matches(match) ? other : super.or(other); in is()
[all …]
/packages/apps/Settings/tests/unit/src/com/android/settings/notification/
DZenModeSettingsIntegrationTest.java4 import static androidx.test.espresso.assertion.ViewAssertions.matches;
40 onView(withText("Calls")).check(matches(isDisplayed())); in testZenModeSettingsPreferences()
41 onView(withText("SMS, MMS, and messaging apps")).check(matches(isDisplayed())); in testZenModeSettingsPreferences()
42 onView(withText("Restrict notifications")).check(matches(isDisplayed())); in testZenModeSettingsPreferences()
43 onView(withText("Duration")).check(matches(isDisplayed())); in testZenModeSettingsPreferences()
44 onView(withText("Schedules")).check(matches(isDisplayed())); in testZenModeSettingsPreferences()
50 onView(withText("Calls")).check(matches(isDisplayed())); in testZenModeBehaviorPreferences()
51 onView(withText("SMS, MMS, and messaging apps")).check(matches(isDisplayed())); in testZenModeBehaviorPreferences()
52 onView(withText("Restrict notifications")).check(matches(isDisplayed())); in testZenModeBehaviorPreferences()
53 onView(withText("Duration")).check(matches(isDisplayed())); in testZenModeBehaviorPreferences()
[all …]
DAppNotificationSettingsTest.java24 import static androidx.test.espresso.assertion.ViewAssertions.matches;
115 matches(isDisplayed())); in launchNotificationSetting_showGroupsWithMultipleChannels()
117 matches(isDisplayed())); in launchNotificationSetting_showGroupsWithMultipleChannels()
119 matches(isDisplayed())); in launchNotificationSetting_showGroupsWithMultipleChannels()
129 .check(matches(isDisplayed())); in launchNotificationSetting_showUngroupedChannels()
140 .check(matches(isDisplayed())); in launchNotificationSetting_showGroupsWithOneChannel()
142 .check(matches(isDisplayed())); in launchNotificationSetting_showGroupsWithOneChannel()
DChannelNotificationSettingsTest.java23 import static androidx.test.espresso.assertion.ViewAssertions.matches;
84 matches(isDisplayed())); in launchNotificationSetting_shouldNotCrash()
106 + " from appearing on this device"))).check(matches(isDisplayed())); in launchNotificationSettings_blockedChannel()
109 onView(allOf(withText("On the lock screen"))).check(matches(isDisplayed())); in launchNotificationSettings_blockedChannel()
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/provisioning/
DProvisioningActivityTest.java27 import static androidx.test.espresso.assertion.ViewAssertions.matches;
362 onView(withText(errorMsgId)).check(matches(isDisplayed())); in testErrorNoFactoryReset()
371 .check(matches(withText(android.R.string.ok))) in testErrorNoFactoryReset()
390 onView(withText(errorMsgId)).check(matches(isDisplayed())); in testErrorFactoryReset()
397 .check(matches(withText(R.string.reset))) in testErrorFactoryReset()
434 onView(withText(R.string.profile_owner_cancel_message)).check(matches(isDisplayed())); in testCancelProfileOwner()
438 .check(matches(withText(R.string.profile_owner_cancel_cancel))) in testCancelProfileOwner()
448 onView(withText(R.string.profile_owner_cancel_message)).check(matches(isDisplayed())); in testCancelProfileOwner()
452 .check(matches(withText(R.string.profile_owner_cancel_ok))) in testCancelProfileOwner()
508 onView(withText(R.string.profile_owner_cancel_message)).check(matches(isDisplayed())); in testCancelProfileOwner_CompProvisioningWithoutSkipConsent()
[all …]
/packages/apps/Launcher3/src/com/android/launcher3/util/
DItemInfoMatcher.java36 boolean matches(ItemInfo info, ComponentName cn); in matches() method
47 if (cn != null && matches(info, cn)) { in filterItemInfos()
54 if (cn != null && matches(s, cn)) { in filterItemInfos()
61 if (cn != null && matches(info, cn)) { in filterItemInfos()
73 return (info, cn) -> matches(info, cn) || matcher.matches(info, cn); in or()
80 return (info, cn) -> matches(info, cn) && matcher.matches(info, cn); in and()
88 return (info, cn) -> !matcher.matches(info, cn); in not()
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/bluetooth/
DBluetoothDevicesGroupPreferenceControllerTest.java123 when(mFilter.matches(mDevice1)).thenReturn(true); in refreshUi_filterMatch_addsToGroup()
137 when(mFilter.matches(mDevice1)).thenReturn(true); in refreshUi_filterMatch_addsToPreferenceMap()
151 when(mFilter.matches(mDevice1)).thenReturn(true); in refreshUi_filterMismatch_removesFromGroup()
158 when(mFilter.matches(mDevice1)).thenReturn(false); in refreshUi_filterMismatch_removesFromGroup()
168 when(mFilter.matches(mDevice1)).thenReturn(true); in refreshUi_filterMismatch_removesFromPreferenceMap()
175 when(mFilter.matches(mDevice1)).thenReturn(false); in refreshUi_filterMismatch_removesFromPreferenceMap()
192 when(mFilter.matches(mDevice1)).thenReturn(true); in refreshUi_devices_showsGroup()
203 when(mFilter.matches(mDevice1)).thenReturn(true); in onBluetoothStateChanged_turningOff_clearsPreferences()
217 when(mFilter.matches(mDevice1)).thenReturn(true); in onDeviceAdded_refreshesUi()
231 when(mFilter.matches(any(BluetoothDevice.class))).thenReturn(true); in onDeviceDeleted_refreshesUi()
[all …]
/packages/apps/TvSettings/Settings/tests/robotests/src/com/android/tv/settings/device/storage/
DSettingsStorageServiceTest.java88 public boolean matches(Intent argument) { in testFormatAsPublic_success_fromPrivate()
89 return super.matches(argument) in testFormatAsPublic_success_fromPrivate()
118 public boolean matches(Intent argument) { in testFormatAsPublic_success_fromNonPrivate()
119 return super.matches(argument) in testFormatAsPublic_success_fromNonPrivate()
144 public boolean matches(Intent argument) { in testFormatAsPublic_failure()
145 return super.matches(argument) in testFormatAsPublic_failure()
176 public boolean matches(Intent argument) { in testFormatAsPrivate_success()
177 return super.matches(argument) in testFormatAsPrivate_success()
203 public boolean matches(Intent argument) { in testFormatAsPrivate_failure()
204 return super.matches(argument) in testFormatAsPrivate_failure()
[all …]
/packages/apps/Settings/tests/unit/src/com/android/settings/wifi/
DWifiSettingsUiTest.java21 import static androidx.test.espresso.assertion.ViewAssertions.matches;
195 matches(isDisplayed())); in shouldShowWifiPreferences()
217 withEffectiveVisibility(VISIBLE))).check(matches(isDisplayed())); in savedNetworksExist_shouldShowSavedNetworksButton()
228 matches(isDisplayed())); in onDisableWifi_seeOffMessage()
251 matches(isDisplayed())); in onConnected_shouldSeeConnectedMessage()
277 onView(withText(TEST_SSID)).check(matches(isDisplayed())); in changingSecurityStateOnApShouldNotCauseMultipleListItems()
280 onView(withText(TEST_SSID)).check(matches(isDisplayed())); in changingSecurityStateOnApShouldNotCauseMultipleListItems()
283 onView(withText(TEST_SSID)).check(matches(isDisplayed())); in changingSecurityStateOnApShouldNotCauseMultipleListItems()
329 onView(withText(resourceId(STRING, WIFI_PASSWORD))).check(matches(isDisplayed())); in wrongPasswordSavedNetwork()
330 onView(withText(resourceId(STRING, WIFI_SHOW_PASSWORD))).check(matches(isDisplayed())); in wrongPasswordSavedNetwork()
[all …]
DWifiCallingSettingUiTest.java21 import static androidx.test.espresso.assertion.ViewAssertions.matches;
233 onView(withText(SUBSCRIPTION0_NAME)).check(matches(isSelected())); in testDualSimUi()
242 onView(withText(SUBSCRIPTION1_NAME)).check(matches(isSelected())); in testDualSimUi()
247 v.check(matches(isCompletelyDisplayed())); in checkExists()
277 .check(matches(withText(containsString(statusOn ? "On" : "Off")))); in checkSwitchBarStatus()
294 .check(matches(anything())); in checkEmptyViewStatus()
/packages/apps/ManagedProvisioning/tests/instrumentation/src/com/android/managedprovisioning/preprovisioning/terms/
DTermsActivityTest.java22 import static androidx.test.espresso.assertion.ViewAssertions.matches;
115 onView(withText(HEADER_0_TOP)).check(matches(isDisplayed())); in expanderTest()
117 onView(withText(d.mHeader)).check(matches(isDisplayed())); in expanderTest()
125 onView(withText(CONTENT_1)).check(matches(isDisplayed())); in expanderTest()
130 onView(withText(CONTENT_3)).check(matches(isDisplayed())); in expanderTest()
139 onView(withText(CONTENT_1)).check(matches(isDisplayed())); in expanderTest()
143 onView(withId(R.id.disclaimer_content)).check(matches(withText("item1\nitem2\n"))); in expanderTest()
152 matches(not(isDisplayed())); in isNotDisplayed()
/packages/apps/Dialer/java/com/android/dialer/searchfragment/
DREADME.md53 * Initial match (957 matches [W]illiam [J]ohn [S]mith)
54 * Number + name match (1800946 matches [1800-Win]-A-Prize)
56 * Simple number match (510333 matches [510-333]-7596)
57 * Country-code agnostic matching for E164 normalized numbers (9177 matches
59 * Country-code agnostic matching (510333 matches 1-[510-333]-7596)
60 * Area-code agnostic matching (333 matches 510-[333]-7596)
62 * Simple name match (564 matches [Joh]n)
/packages/apps/Contacts/src/com/android/contacts/quickcontact/
DResolveCache.java135 final List<ResolveInfo> matches = mPackageManager.queryIntentActivities(intent, in getEntry() local
140 final int size = matches.size(); in getEntry()
142 bestResolve = matches.get(0); in getEntry()
144 bestResolve = getBestResolve(intent, matches); in getEntry()
168 protected ResolveInfo getBestResolve(Intent intent, List<ResolveInfo> matches) { in getBestResolve() argument
182 for (ResolveInfo info : matches) { in getBestResolve()
193 return firstSystem != null ? firstSystem : matches.get(0); in getBestResolve()
/packages/providers/ContactsProvider/src/com/android/providers/contacts/aggregation/util/
DRawContactMatcher.java310 final List<MatchScore> matches = new ArrayList<>(); in pickBestMatches() local
318 matches.add(score); in pickBestMatches()
325 matches.add(score); in pickBestMatches()
328 return matches; in pickBestMatches()
336 List<MatchScore> matches = mScoreList.subList(0, mScoreCount); in pickBestMatches() local
337 Collections.sort(matches); in pickBestMatches()
340 MatchScore matchScore = matches.get(i); in pickBestMatches()
348 return matches.subList(0, count); in pickBestMatches()
DNameDistance.java110 int matches = 0; in getDistance() local
127 matches++; in getDistance()
133 if (matches == 0) { in getDistance()
151 float m = matches; in getDistance()
/packages/apps/Launcher3/src/com/android/launcher3/
DAllAppsList.java129 final List<LauncherActivityInfo> matches = launcherApps.getActivityList(packageName, in addPackage() local
132 for (LauncherActivityInfo info : matches) { in addPackage()
158 if (matcher.matches(info, info.componentName)) { in updateDisabledFlags()
180 final List<LauncherActivityInfo> matches = launcherApps.getActivityList(packageName, in updatePackage() local
182 if (matches.size() > 0) { in updatePackage()
189 if (!findActivity(matches, applicationInfo.componentName)) { in updatePackage()
199 for (final LauncherActivityInfo info : matches) { in updatePackage()
/packages/apps/Contacts/tests/src/com/android/contacts/tests/
DContactsMatchers.java73 public boolean matches(Object o) { in hasCount()
89 public boolean matches(Object o) {
107 public boolean matches(Object o) {
113 if (rowMatcher.matches(cursor)) return true;
131 public boolean matches(Object o) {
/packages/services/Car/car-usb-handler/src/android/car/usb/handler/
DUsbDeviceHandlerResolver.java164 List<UsbHandlerPackage> matches = getDeviceMatches(device, intent, false); in doHandleResolveHandlers() local
166 Log.d(TAG, "matches size: " + matches.size()); in doHandleResolveHandlers()
169 for (UsbHandlerPackage pkg : matches) { in doHandleResolveHandlers()
222 List<UsbHandlerPackage> matches = new ArrayList<>(); in getDeviceMatches() local
246 matches.add(new UsbHandlerPackage(activity, aoapService)); in getDeviceMatches()
250 return matches; in getDeviceMatches()
297 if (forAoap || filter.matches(device)) { in packageMatches()
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/util/bluetooth/
DBluetoothNameUtils.java47 if (!matcher.matches()) { in getSetupType()
71 if (!matcher.matches()) { in getColorConfiguration()
80 if (!cm.matches()) { in getColorConfiguration()
99 return matcher.matches(); in isValidName()
/packages/apps/QuickSearchBox/src/com/android/quicksearchbox/
DLevenshteinSuggestionFormatter.java45 final int[] matches = findMatches(queryTokens, suggestionTokens); in formatSuggestion() local
49 Log.d(TAG, "matches = " + matches); in formatSuggestion()
53 final int matchesLen = matches.length; in formatSuggestion()
57 int thisMatch = matches[i]; in formatSuggestion()
/packages/apps/Launcher3/src/com/android/launcher3/allapps/search/
DDefaultAppSearchAlgorithm.java67 if (matches(info, queryTextLower, matcher)) { in getTitleMatchResult()
74 public static boolean matches(AppInfo info, String query, StringMatcher matcher) { in matches() method in DefaultAppSearchAlgorithm
95 matcher.matches(query, title.substring(i, i + queryLength))) { in matches()
165 public boolean matches(String query, String target) { in matches() method in DefaultAppSearchAlgorithm.StringMatcher
/packages/apps/Settings/tests/unit/src/com/android/settings/fuelgauge/batterytip/
DRestrictAppTest.java20 import static androidx.test.espresso.assertion.ViewAssertions.matches;
72 onView(withText("Restrict 1 app")).check(matches(isDisplayed())); in batterySettings_hasOneAnomaly_showAnomaly()
87 onView(withText("Restrict 2 apps")).check(matches(isDisplayed())); in batterySettings_hasTwoAnomalies_showAnomalies()
102 onView(withText("2 apps recently restricted")).check(matches(isDisplayed())); in batterySettings_hasAutoHandledAnomalies_showAutoHandled()
/packages/apps/DocumentsUI/tests/common/com/android/documentsui/bots/
DMatchers.java20 import static androidx.test.espresso.assertion.ViewAssertions.matches;
44 vi.check(matches(matcher)); in present()
45 vi.check(matches(isDisplayed())); in present()
DUiBot.java21 import static androidx.test.espresso.assertion.ViewAssertions.matches;
103 .check(matches(withToolbarTitle(is(expected)))); in assertWindowTitle()
136 .check(matches(withText(is(expected)))); in assertDialogText()
253 onView(withId(android.R.id.button1)).check(matches(hasFocus())); in assertDialogOkButtonFocused()
306 return textMatcher.matches(toolbar.getTitle()); in withToolbarTitle()

12345678