Home
last modified time | relevance | path

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

123

/libcore/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/
DPattern2Test.java106 private void testCategory(String cat, String... matches) { in testCategory() argument
112 for (int j = 0; j < matches.length; j++) { in testCategory()
113 String t = matches[j]; in testCategory()
119 "by pattern '"+pat, p.matcher(t).matches()); in testCategory()
121 "be matched by pattern '"+npat, pn.matcher(t).matches()); in testCategory()
124 "by pattern '"+pat, p.matcher(t).matches()); in testCategory()
126 "not be matched by pattern '"+npat, pn.matcher(t).matches()); in testCategory()
138 assertTrue(m.matches()); in testCapturingGroups()
144 assertTrue(m.matches()); in testCapturingGroups()
155 assertTrue(m.matches()); in testCapturingGroups()
[all …]
DPatternTest.java305 assertFalse(mat.matches()); in testFlagsCase1()
313 assertTrue(mat.matches()); in testFlagsCase2()
321 assertTrue(mat.matches()); in testFlagsCase3()
329 assertTrue(mat.matches()); in testFlagsCase4()
337 assertTrue(mat.matches()); in testFlagsCase5()
345 assertFalse(mat.matches()); in testFlagsCase6()
353 assertFalse(mat.matches()); in testFlagsCase7()
361 assertTrue(mat.matches()); in testFlagsCase8()
369 assertTrue(mat.matches()); in testFlagsCase9()
377 assertFalse(mat.matches()); in testFlagsCase10()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/regex/
DPattern2Test.java34 assertTrue(m1.matches()); in testSimpleMatch()
39 assertFalse(m2.matches()); in testSimpleMatch()
43 assertTrue(Pattern.matches("foo.*", "foo123")); in testSimpleMatch()
44 assertFalse(Pattern.matches("foo.*", "fox")); in testSimpleMatch()
46 assertFalse(Pattern.matches("bar", "foobar")); in testSimpleMatch()
48 assertTrue(Pattern.matches("", "")); in testSimpleMatch()
365 if (m.matches()) { in testEscapes()
415 assertTrue(m.matches()); in testCharacterClasses()
417 assertTrue(m.matches()); in testCharacterClasses()
419 assertFalse(m.matches()); in testCharacterClasses()
[all …]
DMatcherTest.java46 assertFalse(m.matches()); in testRegionsIntInt()
51 assertTrue(m.matches()); in testRegionsIntInt()
114 assertTrue(m.matches()); in testResetCharSequence()
116 assertFalse(m.matches()); in testResetCharSequence()
228 mat.matches(); in testGroupint()
253 mat.matches(); in testGroupint()
269 mat.matches(); in testGroup()
280 mat.matches(); in testGroup()
293 mat.matches(); in testGroupPossessive()
320 + posSeq[i][j], mat.matches()); in testMatchesMisc()
[all …]
/libcore/luni/src/test/java/libcore/java/nio/file/
DLinuxFileSystemTest.java182 assertTrue(pathMatcher.matches(Paths.get("f.java"))); in test_getPathMatcher_glob()
183 assertFalse(pathMatcher.matches(Paths.get("f"))); in test_getPathMatcher_glob()
186 assertTrue(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob()
187 assertFalse(pathMatcher.matches(Paths.get("f"))); in test_getPathMatcher_glob()
190 assertTrue(pathMatcher.matches(Paths.get("f.java"))); in test_getPathMatcher_glob()
191 assertTrue(pathMatcher.matches(Paths.get("f.class"))); in test_getPathMatcher_glob()
192 assertFalse(pathMatcher.matches(Paths.get("f.clas"))); in test_getPathMatcher_glob()
193 assertFalse(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob()
196 assertTrue(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob()
197 assertFalse(pathMatcher.matches(Paths.get("f.tl"))); in test_getPathMatcher_glob()
[all …]
/libcore/luni/src/test/java/libcore/java/util/regex/
DOldAndroidRegexTest.java29 assertTrue("Should match.", m.matches()); in testMatches()
34 assertFalse("Should not match.", m.matches()); in testMatches()
38 assertFalse("Should not match.", m.matches()); in testMatches()
42 assertFalse("Should not match.", m.matches()); in testMatches()
47 assertTrue(m.matches()); in testMatches()
49 assertTrue(m.matches()); in testMatches()
53 assertFalse(m.matches()); in testMatches()
55 assertFalse(m.matches()); in testMatches()
59 assertTrue(m.matches()); in testMatches()
62 assertFalse(m.matches()); in testMatches()
[all …]
DOldMatcherTest.java315 assertTrue(mat.matches()); in testSEOLsymbols()
360 mat.matches(); in testGroupCount()
407 assertTrue(mat.matches()); in testMatchesURI()
417 assertTrue(Pattern.compile("\\x61a").matcher("aa").matches()); in testUnicode()
419 assertTrue(Pattern.compile("\\0141a").matcher("aa").matches()); in testUnicode()
420 assertTrue(Pattern.compile("\\0777").matcher("?7").matches()); in testUnicode()
425 assertTrue(Pattern.compile("\\p{Ll}").matcher("k").matches()); // Unicode lower case in testUnicodeCategory()
426 assertTrue(Pattern.compile("\\P{Ll}").matcher("K").matches()); // Unicode non-lower in testUnicodeCategory()
428 assertTrue(Pattern.compile("\\p{Lu}").matcher("K").matches()); // Unicode upper case in testUnicodeCategory()
429 assertTrue(Pattern.compile("\\P{Lu}").matcher("k").matches()); // Unicode non-upper in testUnicodeCategory()
[all …]
/libcore/ojluni/src/test/java/util/regex/
DRegExTest.java239 assertThrows(NullPointerException.class, () -> Pattern.matches(null, null)); in nullArgumentTest()
240 assertThrows(NullPointerException.class, () -> Pattern.matches("xyz", null)); in nullArgumentTest()
246 m.matches(); in nullArgumentTest()
602 assertTrue(matcher.matches()); in negatedCharClassTest()
972 assertTrue(m.matches()); in nonCaptureRepetitionTest()
983 boolean condition = !matcher.matches() || in notCapturedGroupCurlyMatchTest()
1234 assertTrue(matcher.matches()); in serializeTest()
1239 assertTrue(serializedPattern.matcher("Ab").matches()); in serializeTest()
1240 assertFalse(serializedPattern.matcher("AB").matches()); in serializeTest()
1388 assertTrue(matcher.matches()); in commentsTest()
[all …]
/libcore/tools/expected_upstream/
Dojluni_modify_expectation.py178 matches = openjdk_finder.match_path_prefix(
181 matches += openjdk_finder.match_classname_prefix(
199 autocomp_result += list(filter(source_not_exists, matches))
208 matches = list(filter(lambda e: dst_path == e.dst_path, expected_entries))
209 if not matches:
211 entry: ExpectedUpstreamEntry = matches[0]
234 matches = list(filter(lambda e: dst_path == e.dst_path, expected_entries))
235 if not matches:
238 entry: ExpectedUpstreamEntry = matches[0]
259 matches = list(
[all …]
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/func/
DKeyGeneratorThread.java44 int matches = 0; in test() local
47 matches++; in test()
50 if (matches > array1.length / 2) { in test()
55 matches = 0; in test()
64 matches++; in test()
/libcore/ojluni/src/main/java/javax/net/ssl/
DSNIHostName.java363 public boolean matches(SNIServerName serverName) { in matches() method in SNIHostName.SNIHostNameMatcher
387 if (pattern.matcher(asciiName).matches()) { in matches()
393 return pattern.matcher(IDN.toUnicode(asciiName)).matches(); in matches()
DSNIMatcher.java104 public abstract boolean matches(SNIServerName serverName); in matches() method in SNIMatcher
/libcore/metrictests/memory/apps/src/libcore/heapdumper/
DActions.java78 boolean matches = m.matches(); in run()
/libcore/ojluni/src/test/java/lang/StringBuffer/
DIndexOf.java122 int matches = 0; in compareIndexOfLastIndexOf() local
125 matches++; in compareIndexOfLastIndexOf()
126 if (matches > 1) in compareIndexOfLastIndexOf()
/libcore/support/src/test/java/libcore/java/security/
DCpuFeatures.java54 if (machine.matches(type.machineRegex)) { in currentArch()
156 if (line.matches(regex)) { in cpuFieldContainsAes()
/libcore/ojluni/src/main/java/java/nio/file/
DPathMatcher.java48 boolean matches(Path path); in matches() method
/libcore/ojluni/src/test/java/time/tck/java/time/
DAbstractTCKTest.java133 …oid assertSerializedBySer(Object object, byte[] expectedBytes, byte[]... matches) throws Exception… in assertSerializedBySer() argument
164 if (matches.length > 0) { in assertSerializedBySer()
165 for (byte[] match : matches) { in assertSerializedBySer()
/libcore/ojluni/src/main/java/sun/net/spi/
DDefaultProxySelector.java374 boolean matches = pattern.matcher(urlhost).matches(); in shouldNotUseProxyFor()
375 return matches; in shouldNotUseProxyFor()
/libcore/luni/src/test/java/libcore/javax/crypto/spec/
DAlgorithmParametersTestPBES2.java233 assertTrue(ap.toString().matches("(?i:.*hmacsha" + shaVariant + ".*)")); in test_correctNames()
234 assertTrue(ap.toString().matches("(?i:.*aes" + +keySize + ".*)")); in test_correctNames()
/libcore/ojluni/src/test/java/lang/invoke/common/test/java/lang/invoke/lib/
DCodeCacheOverflowProcessor.java49 && causeOfT.getMessage().matches(".*[Oo]ut of space" in isThrowableCausedByVME()
/libcore/ojluni/src/main/java/java/util/regex/
DPattern.java1030 public static boolean matches(String regex, CharSequence input) { in matches() method in Pattern
1033 return m.matches(); in matches()
5674 return s -> matcher(s).matches(); in asMatchPredicate()
/libcore/ojluni/src/main/java/sun/nio/fs/
DUnixFileSystem.java309 public boolean matches(Path path) {
310 return pattern.matcher(path.toString()).matches();
/libcore/ojluni/src/main/java/java/util/logging/
DLevel.java410 KnownLevel o = KnownLevel.matches(this); in readResolve()
601 static synchronized KnownLevel matches(Level l) { in matches() method in Level.KnownLevel
/libcore/luni/src/test/java/libcore/java/lang/
DOldStringTest.java501 + strings[i][j], strings[i][j].matches(patterns[i])); in test_matches()
502 assertFalse("" + i, strings[i][j].matches(patternsInc[i])); in test_matches()
/libcore/ojluni/src/test/java/time/tck/java/time/format/
DTCKZoneIdPrinterParser.java245 if (text.matches("[^A-Z]*[A-Z].*")) { // if input has letters in test_ZoneId_parseSuccess_caseSensitive()
297 if (text.matches("[^A-Z]*[A-Z].*")) { // if input has letters in test_ZoneOrOffsetId_parseSuccess_caseSensitive()

123