/libcore/luni/src/test/java/libcore/java/nio/ |
D | OldAndroidNIOTest.java | 138 assertEquals((byte) 0xA7, b.get(7)); in byteBufferTest() 140 b.get(12); in byteBufferTest() 146 b.get(-10); in byteBufferTest() 154 assertEquals((byte) 0xA0, b.get()); in byteBufferTest() 155 assertEquals((byte) 0xA1, b.get()); in byteBufferTest() 156 assertEquals((byte) 0xA2, b.get()); in byteBufferTest() 157 assertEquals((byte) 0xA3, b.get()); in byteBufferTest() 158 assertEquals((byte) 0xA4, b.get()); in byteBufferTest() 159 assertEquals((byte) 0xA5, b.get()); in byteBufferTest() 160 assertEquals((byte) 0xA6, b.get()); in byteBufferTest() [all …]
|
D | BufferTest.java | 77 mbb.get(buf1); in testDevZeroMap() 108 mbb.get(buf2); in testDevZeroMapRW() 138 b.order(ByteOrder.BIG_ENDIAN).asCharBuffer().get(chars, 1, 4); in testByteSwappedBulkGet() 140 b.order(ByteOrder.LITTLE_ENDIAN).asCharBuffer().get(chars, 1, 4); in testByteSwappedBulkGet() 144 b.order(ByteOrder.BIG_ENDIAN).asDoubleBuffer().get(doubles, 1, 1); in testByteSwappedBulkGet() 148 b.order(ByteOrder.LITTLE_ENDIAN).asDoubleBuffer().get(doubles, 1, 1); in testByteSwappedBulkGet() 154 b.order(ByteOrder.BIG_ENDIAN).asFloatBuffer().get(floats, 1, 2); in testByteSwappedBulkGet() 159 b.order(ByteOrder.LITTLE_ENDIAN).asFloatBuffer().get(floats, 1, 2); in testByteSwappedBulkGet() 166 b.order(ByteOrder.BIG_ENDIAN).asIntBuffer().get(ints, 1, 2); in testByteSwappedBulkGet() 171 b.order(ByteOrder.LITTLE_ENDIAN).asIntBuffer().get(ints, 1, 2); in testByteSwappedBulkGet() [all …]
|
/libcore/luni/src/test/java/libcore/java/nio/file/ |
D | LinuxPathTest.java | 64 private static final Path dummyPath = Paths.get("dummyPath"); 81 assertEquals(Paths.get("/"), dummyPath.toAbsolutePath().getRoot()); in test_getRoot() 90 assertEquals(Paths.get("data"), Paths.get("/data").getFileName()); in test_getFileName() 91 assertEquals(Paths.get("data"), Paths.get("/data/").getFileName()); in test_getFileName() 92 assertEquals(Paths.get(".."), Paths.get("/data/dir1/..").getFileName()); in test_getFileName() 98 assertEquals(Paths.get("rootDir"), Paths.get("rootDir/dir").getParent()); in test_getParent() 103 assertEquals(0, Paths.get("/").getNameCount()); in test_getNameCount() 104 assertEquals(1, Paths.get("/dir").getNameCount()); in test_getNameCount() 105 assertEquals(2, Paths.get("/dir/dir").getNameCount()); in test_getNameCount() 106 assertEquals(2, Paths.get("/dir/..").getNameCount()); in test_getNameCount() [all …]
|
D | LinuxFileSystemTest.java | 86 assertTrue(pathMap.get(Paths.get("/"))); in test_getRootDirectories() 130 assertTrue(pathMatcher.matches(Paths.get("f.java"))); in test_getPathMatcher_glob() 131 assertFalse(pathMatcher.matches(Paths.get("f"))); in test_getPathMatcher_glob() 134 assertTrue(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob() 135 assertFalse(pathMatcher.matches(Paths.get("f"))); in test_getPathMatcher_glob() 138 assertTrue(pathMatcher.matches(Paths.get("f.java"))); in test_getPathMatcher_glob() 139 assertTrue(pathMatcher.matches(Paths.get("f.class"))); in test_getPathMatcher_glob() 140 assertFalse(pathMatcher.matches(Paths.get("f.clas"))); in test_getPathMatcher_glob() 141 assertFalse(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob() 144 assertTrue(pathMatcher.matches(Paths.get("f.t"))); in test_getPathMatcher_glob() [all …]
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | AtomicBooleanTest.java | 31 assertTrue(new AtomicBoolean(true).get()); in testConstructor() 32 assertFalse(new AtomicBoolean(false).get()); in testConstructor() 40 assertFalse(ai.get()); in testConstructor2() 48 assertTrue(ai.get()); in testGetSet() 50 assertFalse(ai.get()); in testGetSet() 52 assertTrue(ai.get()); in testGetSet() 60 assertTrue(ai.get()); in testGetLazySet() 62 assertFalse(ai.get()); in testGetLazySet() 64 assertTrue(ai.get()); in testGetLazySet() 73 assertFalse(ai.get()); in testCompareAndSet() [all …]
|
D | AtomicIntegerTest.java | 36 assertEquals(1, ai.get()); in testConstructor() 44 assertEquals(0, ai.get()); in testConstructor2() 52 assertEquals(1, ai.get()); in testGetSet() 54 assertEquals(2, ai.get()); in testGetSet() 56 assertEquals(-3, ai.get()); in testGetSet() 64 assertEquals(1, ai.get()); in testGetLazySet() 66 assertEquals(2, ai.get()); in testGetLazySet() 68 assertEquals(-3, ai.get()); in testGetLazySet() 78 assertEquals(-4, ai.get()); in testCompareAndSet() 80 assertEquals(-4, ai.get()); in testCompareAndSet() [all …]
|
D | AtomicLongTest.java | 38 assertEquals(1, ai.get()); in testConstructor() 46 assertEquals(0, ai.get()); in testConstructor2() 54 assertEquals(1, ai.get()); in testGetSet() 56 assertEquals(2, ai.get()); in testGetSet() 58 assertEquals(-3, ai.get()); in testGetSet() 66 assertEquals(1, ai.get()); in testGetLazySet() 68 assertEquals(2, ai.get()); in testGetLazySet() 70 assertEquals(-3, ai.get()); in testGetLazySet() 80 assertEquals(-4, ai.get()); in testCompareAndSet() 82 assertEquals(-4, ai.get()); in testCompareAndSet() [all …]
|
D | AtomicLongFieldUpdaterTest.java | 148 assertEquals(1, a.get(this)); in testGetSet() 150 assertEquals(2, a.get(this)); in testGetSet() 152 assertEquals(-3, a.get(this)); in testGetSet() 162 assertEquals(1, a.get(this)); in testGetLazySet() 164 assertEquals(2, a.get(this)); in testGetLazySet() 166 assertEquals(-3, a.get(this)); in testGetLazySet() 178 assertEquals(-4, a.get(this)); in testCompareAndSet() 180 assertEquals(-4, a.get(this)); in testCompareAndSet() 182 assertEquals(7, a.get(this)); in testCompareAndSet() 195 assertEquals(-4, a.get(this)); in testCompareAndSetProtected() [all …]
|
D | AtomicIntegerFieldUpdaterTest.java | 148 assertEquals(1, a.get(this)); in testGetSet() 150 assertEquals(2, a.get(this)); in testGetSet() 152 assertEquals(-3, a.get(this)); in testGetSet() 162 assertEquals(1, a.get(this)); in testGetLazySet() 164 assertEquals(2, a.get(this)); in testGetLazySet() 166 assertEquals(-3, a.get(this)); in testGetLazySet() 178 assertEquals(-4, a.get(this)); in testCompareAndSet() 180 assertEquals(-4, a.get(this)); in testCompareAndSet() 182 assertEquals(7, a.get(this)); in testCompareAndSet() 195 assertEquals(-4, a.get(this)); in testCompareAndSetProtected() [all …]
|
D | AtomicReferenceTest.java | 32 assertSame(one, ai.get()); in testConstructor() 40 assertNull(ai.get()); in testConstructor2() 48 assertSame(one, ai.get()); in testGetSet() 50 assertSame(two, ai.get()); in testGetSet() 52 assertSame(m3, ai.get()); in testGetSet() 60 assertSame(one, ai.get()); in testGetLazySet() 62 assertSame(two, ai.get()); in testGetLazySet() 64 assertSame(m3, ai.get()); in testGetLazySet() 74 assertSame(m4, ai.get()); in testCompareAndSet() 76 assertSame(m4, ai.get()); in testCompareAndSet() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
D | BitSetTest.java | 93 assertTrue("Clear didn't clear bit " + i, !eightbs.get(i)); in test_clear() 109 assertFalse("Failed to clear bit", eightbs.get(7)); in test_clearI() 113 assertTrue("Clear cleared incorrect bits", eightbs.get(i)); in test_clearI() 117 assertFalse("Failed to clear bit", eightbs.get(165)); in test_clearI() 180 assertFalse("Shouldn't have flipped bit " + i, bs.get(i)); in test_clearII() 182 assertTrue("Shouldn't have cleared bit " + i, bs.get(i)); in test_clearII() 186 assertFalse("Failed to clear bit " + i, bs.get(i)); in test_clearII() 191 assertFalse("Shouldn't have flipped bit " + i, bs.get(i)); in test_clearII() 193 assertTrue("Shouldn't have cleared bit " + i, bs.get(i)); in test_clearII() 198 assertFalse("Shouldn't have flipped bit " + i, bs.get(i)); in test_clearII() [all …]
|
D | GregorianCalendarTest.java | 66 1972, gc.get(Calendar.YEAR)); in test_ConstructorIII() 68 gc.get(Calendar.MONTH) == Calendar.OCTOBER); in test_ConstructorIII() 70 .get(Calendar.DAY_OF_MONTH)); in test_ConstructorIII() 84 1972, gc.get(Calendar.YEAR)); in test_ConstructorIIIII() 86 gc.get(Calendar.MONTH) == Calendar.OCTOBER); in test_ConstructorIIIII() 88 .get(Calendar.DAY_OF_MONTH)); in test_ConstructorIIIII() 89 assertEquals("Incorrect calendar constructed", 7, gc.get(Calendar.HOUR)); in test_ConstructorIIIII() 91 1, gc.get(Calendar.AM_PM)); in test_ConstructorIIIII() 93 9, gc.get(Calendar.MINUTE)); in test_ConstructorIIIII() 100 5983, gc.get(Calendar.YEAR)); in test_ConstructorIIIII() [all …]
|
/libcore/ojluni/src/test/java/time/test/java/time/chrono/ |
D | TestIsoChronoImpl.java | 100 cal.set(Calendar.YEAR, isoDate.get(YEAR)); in test_IsoChrono_vsCalendar() 101 cal.set(Calendar.MONTH, isoDate.get(MONTH_OF_YEAR) - 1); in test_IsoChrono_vsCalendar() 102 cal.set(Calendar.DAY_OF_MONTH, isoDate.get(DAY_OF_MONTH)); in test_IsoChrono_vsCalendar() 105 …assertEquals(isoDate.get(DAY_OF_MONTH), cal.get(Calendar.DAY_OF_MONTH), "Day mismatch in " + isoDa… in test_IsoChrono_vsCalendar() 106 …assertEquals(isoDate.get(MONTH_OF_YEAR), cal.get(Calendar.MONTH) + 1, "Month mismatch in " + isoDa… in test_IsoChrono_vsCalendar() 107 … assertEquals(isoDate.get(YEAR_OF_ERA), cal.get(Calendar.YEAR), "Year mismatch in " + isoDate); in test_IsoChrono_vsCalendar() 131 cal.set(Calendar.YEAR, isoDate.get(YEAR)); in test_DayOfWeek_IsoChronology_vsCalendar() 132 cal.set(Calendar.MONTH, isoDate.get(MONTH_OF_YEAR) - 1); in test_DayOfWeek_IsoChronology_vsCalendar() 133 cal.set(Calendar.DAY_OF_MONTH, isoDate.get(DAY_OF_MONTH)); in test_DayOfWeek_IsoChronology_vsCalendar() 137 …assertEquals(isoDate.get(DAY_OF_MONTH), cal.get(Calendar.DAY_OF_MONTH), "Day mismatch in " + isoDa… in test_DayOfWeek_IsoChronology_vsCalendar() [all …]
|
D | TestThaiBuddhistChronoImpl.java | 103 cal.set(Calendar.YEAR, thaiDate.get(ChronoField.YEAR)); in test_ThaiBuddhistChrono_vsCalendar() 104 cal.set(Calendar.MONTH, thaiDate.get(ChronoField.MONTH_OF_YEAR) - 1); in test_ThaiBuddhistChrono_vsCalendar() 105 cal.set(Calendar.DAY_OF_MONTH, thaiDate.get(ChronoField.DAY_OF_MONTH)); in test_ThaiBuddhistChrono_vsCalendar() 108 …assertEquals(thaiDate.get(ChronoField.DAY_OF_MONTH), cal.get(Calendar.DAY_OF_MONTH), "Day mismatch… in test_ThaiBuddhistChrono_vsCalendar() 109 …assertEquals(thaiDate.get(ChronoField.MONTH_OF_YEAR), cal.get(Calendar.MONTH) + 1, "Month mismatch… in test_ThaiBuddhistChrono_vsCalendar() 110 …assertEquals(thaiDate.get(ChronoField.YEAR_OF_ERA), cal.get(Calendar.YEAR), "Year mismatch in " + … in test_ThaiBuddhistChrono_vsCalendar() 119 … cal.get(Calendar.YEAR), cal.get(Calendar.MONTH) + 1, cal.get(Calendar.DAY_OF_MONTH)); in calToString()
|
/libcore/luni/src/test/java/libcore/sun/security/x509/ |
D | AlgorithmIdTest.java | 30 assertEquals("1.3.14.3.2.26", AlgorithmId.get("SHA-1").getOID().toString()); in test_get_String() 31 assertEquals("1.3.14.3.2.26", AlgorithmId.get("SHA1").getOID().toString()); in test_get_String() 32 assertEquals("2.16.840.1.101.3.4.2.4", AlgorithmId.get("SHA-224").getOID().toString()); in test_get_String() 35 assertEquals("2.16.840.1.101.3.4.2.4", AlgorithmId.get("SHA224").getOID().toString()); in test_get_String() 37 assertEquals("2.16.840.1.101.3.4.2.1", AlgorithmId.get("SHA-256").getOID().toString()); in test_get_String() 40 assertEquals("2.16.840.1.101.3.4.2.1", AlgorithmId.get("SHA256").getOID().toString()); in test_get_String() 43 "2.16.840.1.101.3.4.3.1", AlgorithmId.get("SHA224WithDSA").getOID().toString()); in test_get_String() 45 "2.16.840.1.101.3.4.3.2", AlgorithmId.get("SHA256WithDSA").getOID().toString()); in test_get_String() 48 "2.16.840.1.101.3.4.3.1", AlgorithmId.get("sHA224withDSA").getOID().toString()); in test_get_String() 50 "2.16.840.1.101.3.4.3.2", AlgorithmId.get("sHA256withDSA").getOID().toString()); in test_get_String() [all …]
|
/libcore/luni/src/test/java/libcore/java/io/ |
D | OldObjectInputStreamGetFieldTest.java | 128 fields.get("noValue", false); in test_getException() 134 fields.get("noValue", (byte) 0); in test_getException() 140 fields.get("noValue", (char) 0); in test_getException() 146 fields.get("noValue", 0.0); in test_getException() 152 fields.get("noValue", 0.0f); in test_getException() 158 fields.get("noValue", (long) 0); in test_getException() 164 fields.get("noValue", 0); in test_getException() 170 fields.get("noValue", new Object()); in test_getException() 176 fields.get("noValue", (short) 0); in test_getException() 183 fields.get("byteValue", false); in test_getException() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/ |
D | ThreadLocalTest.java | 43 assertEquals("initial", tl.get()); in test_remove() 45 assertEquals("fixture", tl.get()); in test_remove() 47 assertEquals("initial", tl.get()); in test_remove() 56 assertNull("ThreadLocal's initial value is null", l.get()); in test_get() 69 + " but is " + l1.get(), l1.get() == INITIAL_VALUE); in test_get() 82 THREADVALUE.result = l1.get(); in test_get() 107 thrVar.get(); in test_get() 119 assertTrue("ThreadLocal's initial value is " + OBJ, l.get() == OBJ); in test_setLjava_lang_Object() 132 THREADVALUE.result = l.get(); in test_setLjava_lang_Object() 162 assertSame(INITIAL_VALUE, l1.get()); in test_withInitial() [all …]
|
/libcore/support/src/test/java/tests/support/ |
D | Support_ListTest.java | 43 elem = list.get(counter); in runTest() 52 .get(50).equals(new Integer(1000))); in runTest() 55 list.get(51).equals(new Integer(50))); in runTest() 58 list.get(49).equals(new Integer(49))); in runTest() 61 assertTrue("ListTest - a) set failed--did not set", list.get(50) in runTest() 64 list.get(51).equals(new Integer(50))); in runTest() 66 .get(49).equals(new Integer(49))); in runTest() 70 list.get(50).equals(new Integer(50))); in runTest() 73 list.get(51).equals(new Integer(51))); in runTest() 76 list.get(49).equals(new Integer(49))); in runTest() [all …]
|
/libcore/luni/src/test/java/libcore/java/util/function/ |
D | LongPredicateTest.java | 42 assertTrue(alwaysTrueInvoked.get() && alwaysTrue2Invoked.get()); in testAnd() 47 assertTrue(alwaysTrueInvoked.get() && alwaysFalseInvoked.get()); in testAnd() 52 assertTrue(alwaysFalseInvoked.get() && !alwaysFalse2Invoked.get()); in testAnd() 57 assertTrue(alwaysFalseInvoked.get() && !alwaysTrueInvoked.get()); in testAnd() 93 assertTrue(alwaysTrueInvoked.get() && !alwaysTrue2Invoked.get()); in testOr() 98 assertTrue(alwaysTrueInvoked.get() && !alwaysFalseInvoked.get()); in testOr() 103 assertTrue(alwaysFalseInvoked.get() && alwaysFalse2Invoked.get()); in testOr() 108 assertTrue(alwaysFalseInvoked.get() && alwaysTrueInvoked.get()); in testOr()
|
D | IntPredicateTest.java | 48 assertTrue(alwaysTrueInvoked.get() && alwaysTrue2Invoked.get()); in testAnd() 53 assertTrue(alwaysTrueInvoked.get() && alwaysFalseInvoked.get()); in testAnd() 58 assertTrue(alwaysFalseInvoked.get() && !alwaysFalse2Invoked.get()); in testAnd() 63 assertTrue(alwaysFalseInvoked.get() && !alwaysTrueInvoked.get()); in testAnd() 105 assertTrue(alwaysTrueInvoked.get() && !alwaysTrue2Invoked.get()); in testOr() 110 assertTrue(alwaysTrueInvoked.get() && !alwaysFalseInvoked.get()); in testOr() 115 assertTrue(alwaysFalseInvoked.get() && alwaysFalse2Invoked.get()); in testOr() 120 assertTrue(alwaysFalseInvoked.get() && alwaysTrueInvoked.get()); in testOr()
|
D | PredicateTest.java | 48 assertTrue(alwaysTrueInvoked.get() && alwaysTrue2Invoked.get()); in testAnd() 53 assertTrue(alwaysTrueInvoked.get() && alwaysFalseInvoked.get()); in testAnd() 58 assertTrue(alwaysFalseInvoked.get() && !alwaysFalse2Invoked.get()); in testAnd() 63 assertTrue(alwaysFalseInvoked.get() && !alwaysTrueInvoked.get()); in testAnd() 105 assertTrue(alwaysTrueInvoked.get() && !alwaysTrue2Invoked.get()); in testOr() 110 assertTrue(alwaysTrueInvoked.get() && !alwaysFalseInvoked.get()); in testOr() 115 assertTrue(alwaysFalseInvoked.get() && alwaysFalse2Invoked.get()); in testOr() 120 assertTrue(alwaysFalseInvoked.get() && alwaysTrueInvoked.get()); in testOr()
|
D | DoublePredicateTest.java | 48 assertTrue(alwaysTrueInvoked.get() && alwaysTrue2Invoked.get()); in testAnd() 53 assertTrue(alwaysTrueInvoked.get() && alwaysFalseInvoked.get()); in testAnd() 58 assertTrue(alwaysFalseInvoked.get() && !alwaysFalse2Invoked.get()); in testAnd() 63 assertTrue(alwaysFalseInvoked.get() && !alwaysTrueInvoked.get()); in testAnd() 105 assertTrue(alwaysTrueInvoked.get() && !alwaysTrue2Invoked.get()); in testOr() 110 assertTrue(alwaysTrueInvoked.get() && !alwaysFalseInvoked.get()); in testOr() 115 assertTrue(alwaysFalseInvoked.get() && alwaysFalse2Invoked.get()); in testOr() 120 assertTrue(alwaysFalseInvoked.get() && alwaysTrueInvoked.get()); in testOr()
|
/libcore/luni/src/test/java/libcore/java/util/concurrent/ |
D | CopyOnWriteArrayListTest.java | 59 bcd.get(1); in testSubListAndNonStructuralChanges() 71 bcd.get(1); in testSubListAndStructuralChanges() 84 bcd.get(1); in testSubListAndSizePreservingStructuralChanges() 200 future.get(); // this will throw the above exception in testAddAllIsAtomic() 303 assertEquals(10.0, l.get(0)); in test_replaceAll() 304 assertEquals(4.0, l.get(1)); in test_replaceAll() 305 assertEquals(-6.0, l.get(2)); in test_replaceAll() 318 assertEquals(-3.0, l.get(0)); in test_sort() 319 assertEquals(2.0, l.get(1)); in test_sort() 320 assertEquals(5.0, l.get(2)); in test_sort() [all …]
|
/libcore/luni/src/main/java/libcore/icu/ |
D | DateUtilsBridge.java | 151 return c2.get(Calendar.JULIAN_DAY) - c1.get(Calendar.JULIAN_DAY); in dayDistance() 155 return c.get(Calendar.MINUTE) == 0 && c.get(Calendar.SECOND) == 0; in onTheHour() 159 return c1.get(Calendar.YEAR) != c2.get(Calendar.YEAR) || in fallOnDifferentDates() 160 c1.get(Calendar.MONTH) != c2.get(Calendar.MONTH) || in fallOnDifferentDates() 161 c1.get(Calendar.DAY_OF_MONTH) != c2.get(Calendar.DAY_OF_MONTH); in fallOnDifferentDates() 165 return c1.get(Calendar.MONTH) == c2.get(Calendar.MONTH); in fallInSameMonth() 169 return c1.get(Calendar.YEAR) == c2.get(Calendar.YEAR); in fallInSameYear() 175 return c.get(Calendar.YEAR) == now.get(Calendar.YEAR); in isThisYear()
|
/libcore/luni/src/test/java/libcore/icu/ |
D | LocaleDataTest.java | 25 LocaleData d = LocaleData.get(l); in testAll() 32 LocaleData l = LocaleData.get(Locale.US); in test_en_US() 60 LocaleData l = LocaleData.get(new Locale("de", "DE")); in test_de_DE() 68 LocaleData l = LocaleData.get(new Locale("cs", "CZ")); in test_cs_CZ() 80 LocaleData l = LocaleData.get(new Locale("ko", "KR")); in test_ko_KR() 89 LocaleData l = LocaleData.get(new Locale("ru", "RU")); in test_ru_RU() 103 LocaleData es = LocaleData.get(new Locale("es")); in testDecimalFormatSymbols_es() 107 LocaleData es_419 = LocaleData.get(new Locale("es", "419")); in testDecimalFormatSymbols_es() 111 LocaleData es_US = LocaleData.get(new Locale("es", "US")); in testDecimalFormatSymbols_es() 115 LocaleData es_MX = LocaleData.get(new Locale("es", "MX")); in testDecimalFormatSymbols_es() [all …]
|