/libcore/ojluni/src/test/java/math/BigDecimal/ |
D | ZeroScalingTests.java | 95 for (BigDecimal zero: zeros) { in addTests() 96 if (Math.abs((long)zero.scale()) < 100 ) { in addTests() 98 int preferredScale = Math.max(zero.scale(), element.scale()); in addTests() 107 BigDecimal result = element.add(zero, mc); in addTests() 114 result = zero.add(element, mc); in addTests() 121 result = element.negate().add(zero, mc); in addTests() 128 result = zero.add(element.negate(), mc); in addTests() 169 for (BigDecimal zero: zeros) { in subtractTests() 170 if (Math.abs((long)zero.scale()) < 100 ) { in subtractTests() 172 int preferredScale = Math.max(zero.scale(), element.scale()); in subtractTests() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/ |
D | BigIntegerTest.java | 29 BigInteger zero = new BigInteger("0", 10); field in BigIntegerTest 89 assertTrue("Random number is negative", bi.compareTo(zero) >= 0); in test_ConstructorILjava_util_Random() 126 assertTrue("Incorrect value for zero", bi.equals(zero)); in test_ConstructorI$B() 212 assertTrue("0=0", zero.equals(BigInteger.valueOf(0))); in test_equalsLjava_lang_Object() 215 assertTrue("0=1", !zero.equals(one)); in test_equalsLjava_lang_Object() 216 assertTrue("0=-1", !zero.equals(minusOne)); in test_equalsLjava_lang_Object() 268 assertTrue("0+0", zero.add(zero).equals(zero)); in test_addLjava_math_BigInteger() 269 assertTrue("0+1", zero.add(one).equals(one)); in test_addLjava_math_BigInteger() 270 assertTrue("1+0", one.add(zero).equals(one)); in test_addLjava_math_BigInteger() 272 assertTrue("0+(-1)", zero.add(minusOne).equals(minusOne)); in test_addLjava_math_BigInteger() [all …]
|
/libcore/luni/src/test/java/libcore/java/lang/ |
D | ByteTest.java | 22 final byte zero = (byte) 0; in test_compare() 26 assertTrue(Byte.compare(zero, zero) == 0); in test_compare() 27 assertTrue(Byte.compare(max, zero) > 0); in test_compare() 29 assertTrue(Byte.compare(zero, max) < 0); in test_compare() 30 assertTrue(Byte.compare(zero, min) > 0); in test_compare() 31 assertTrue(Byte.compare(min, zero) < 0); in test_compare()
|
D | ShortTest.java | 22 final short zero = 0; in test_compare() local 26 assertTrue(Short.compare(zero, zero) == 0); in test_compare() 27 assertTrue(Short.compare(max, zero) > 0); in test_compare() 29 assertTrue(Short.compare(zero, max) < 0); in test_compare() 30 assertTrue(Short.compare(zero, min) > 0); in test_compare() 31 assertTrue(Short.compare(min, zero) < 0); in test_compare()
|
D | LongTest.java | 40 final long zero = 0L; in testCompare() local 44 assertTrue(Long.compare(zero, zero) == 0); in testCompare() 45 assertTrue(Long.compare(max, zero) > 0); in testCompare() 47 assertTrue(Long.compare(zero, max) < 0); in testCompare() 48 assertTrue(Long.compare(zero, min) > 0); in testCompare() 49 assertTrue(Long.compare(min, zero) < 0); in testCompare()
|
D | IntegerTest.java | 56 final int zero = 0; in testCompare() local 60 assertTrue(Integer.compare(zero, zero) == 0); in testCompare() 61 assertTrue(Integer.compare(max, zero) > 0); in testCompare() 63 assertTrue(Integer.compare(zero, max) < 0); in testCompare() 64 assertTrue(Integer.compare(zero, min) > 0); in testCompare() 65 assertTrue(Integer.compare(min, zero) < 0); in testCompare()
|
/libcore/ojluni/src/test/sun/invoke/util/ |
D | WrapperTest.java | 56 assertTrue(x == Wrapper.SHORT.zero()); in testShortZeroConversion() 69 assertTrue(x == Wrapper.INT.zero()); in testIntZeroConversion() 82 assertTrue(x == Wrapper.LONG.zero()); in testLongZeroConversion() 95 assertTrue(x == Wrapper.BYTE.zero()); in testByteZeroConversion() 108 assertTrue(x == Wrapper.CHAR.zero()); in testCharacterZeroConversion()
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | ThreadLocalTest.java | 34 return zero; 58 assertSame(itl.get(), zero); in testRemoveITL() local 62 assertSame(itl.get(), zero); in testRemoveITL() local
|
D | ConcurrentLinkedDequeTest.java | 204 assertTrue(q.offer(zero)); in testOffer() 206 assertSame(zero, q.peekFirst()); in testOffer() 215 assertTrue(q.offerFirst(zero)); in testOfferFirst() 218 assertSame(zero, q.peekLast()); in testOfferFirst() 226 assertTrue(q.offerLast(zero)); in testOfferLast() 228 assertSame(zero, q.peekFirst()); in testOfferLast() 270 assertTrue(q.add(zero)); in testAdd() 272 assertSame(zero, q.peekFirst()); in testAdd() 281 q.addFirst(zero); in testAddFirst() 284 assertSame(zero, q.peekLast()); in testAddFirst() [all …]
|
D | SynchronousQueueTest.java | 65 assertFalse(q.offer(zero)); in testEmptyFull() 266 assertSame(zero, q.poll(LONG_DELAY_MS, MILLISECONDS)); in testTimedPollWithOffer() 287 try { assertTrue(q.offer(zero, LONG_DELAY_MS, MILLISECONDS)); } in testTimedPollWithOffer() 340 assertFalse(q.contains(zero)); 363 Integer[] ints = new Integer[1]; ints[0] = zero; 376 Integer[] ints = new Integer[1]; ints[0] = zero; 389 Integer[] ints = new Integer[1]; ints[0] = zero; 543 assertFalse(clone.offer(zero));
|
D | ArrayDequeTest.java | 200 assertTrue(q.offer(zero)); in testOffer() 202 assertSame(zero, q.peekFirst()); in testOffer() 211 assertTrue(q.offerFirst(zero)); in testOfferFirst() 214 assertSame(zero, q.peekLast()); in testOfferFirst() 222 assertTrue(q.offerLast(zero)); in testOfferLast() 224 assertSame(zero, q.peekFirst()); in testOfferLast() 266 assertTrue(q.add(zero)); in testAdd() 268 assertSame(zero, q.peekFirst()); in testAdd() 277 q.addFirst(zero); in testAddFirst() 280 assertSame(zero, q.peekLast()); in testAddFirst() [all …]
|
D | AtomicReferenceTest.java | 118 assertSame(one, ai.getAndSet(zero)); in testGetAndSet() 119 assertSame(zero, ai.getAndSet(m10)); in testGetAndSet()
|
/libcore/ojluni/src/test/java/util/concurrent/tck/ |
D | ThreadLocalTest.java | 58 return zero; 82 assertSame(itl.get(), zero); in testRemoveITL() local 86 assertSame(itl.get(), zero); in testRemoveITL() local
|
D | ConcurrentLinkedDequeTest.java | 238 assertTrue(q.offer(zero)); in testOffer() 240 assertSame(zero, q.peekFirst()); in testOffer() 249 assertTrue(q.offerFirst(zero)); in testOfferFirst() 252 assertSame(zero, q.peekLast()); in testOfferFirst() 260 assertTrue(q.offerLast(zero)); in testOfferLast() 262 assertSame(zero, q.peekFirst()); in testOfferLast() 304 assertTrue(q.add(zero)); in testAdd() 306 assertSame(zero, q.peekFirst()); in testAdd() 315 q.addFirst(zero); in testAddFirst() 318 assertSame(zero, q.peekLast()); in testAddFirst() [all …]
|
D | SynchronousQueueTest.java | 86 assertFalse(q.offer(zero)); in testEmptyFull() 287 assertSame(zero, q.poll(LONG_DELAY_MS, MILLISECONDS)); in testTimedPollWithOffer() 308 try { assertTrue(q.offer(zero, LONG_DELAY_MS, MILLISECONDS)); } in testTimedPollWithOffer() 361 assertFalse(q.contains(zero)); 384 Integer[] ints = new Integer[1]; ints[0] = zero; 397 Integer[] ints = new Integer[1]; ints[0] = zero; 410 Integer[] ints = new Integer[1]; ints[0] = zero; 563 assertFalse(clone.offer(zero));
|
D | ArrayDequeTest.java | 267 assertTrue(q.offer(zero)); in testOffer() 269 assertSame(zero, q.peekFirst()); in testOffer() 278 assertTrue(q.offerFirst(zero)); in testOfferFirst() 281 assertSame(zero, q.peekLast()); in testOfferFirst() 289 assertTrue(q.offerLast(zero)); in testOfferLast() 291 assertSame(zero, q.peekFirst()); in testOfferLast() 333 assertTrue(q.add(zero)); in testAdd() 335 assertSame(zero, q.peekFirst()); in testAdd() 344 q.addFirst(zero); in testAddFirst() 347 assertSame(zero, q.peekLast()); in testAddFirst() [all …]
|
D | AtomicReferenceTest.java | 141 assertSame(one, ai.getAndSet(zero)); in testGetAndSet() 142 assertSame(zero, ai.getAndSet(m10)); in testGetAndSet()
|
/libcore/luni/src/test/java/libcore/java/util/ |
D | TimSortTest.java | 69 final Integer zero = 0; in createBugTriggerData() local 74 bugTriggerData[i] = zero; in createBugTriggerData()
|
/libcore/ojluni/src/test/java/lang/invoke/ |
D | LoopCombinatorTest.java | 311 Object zero; in snip() local 313 zero = MethodHandles.zero(argType).invoke(); in snip() 317 return MethodHandles.insertArguments(mh, argPos, zero); in snip() 449 MethodHandle zero = MethodHandles.zero(void.class); in testCountedLoopVoidInit() local 453 if (useNull) zero = null; in testCountedLoopVoidInit() 456 … System.out.println("testCountedLoopVoidInit i="+i+" : "+Arrays.asList(init, zero, body)); in testCountedLoopVoidInit() 457 MethodHandle loop = MethodHandles.countedLoop(init, zero, body); in testCountedLoopVoidInit() 617 MethodHandle zero = MethodHandles.zero(void.class); in countedLoopNegativeData() local 622 … {zero, one, zero, zero, String.format("start/end must return int %s, %s", zero, one)}, in countedLoopNegativeData() 623 … {one, zero, zero, zero, String.format("start/end must return int %s, %s", one, zero)}, in countedLoopNegativeData() [all …]
|
D | ConstantIdentityMHTest.java | 61 assertEquals(MethodHandles.zero(expectedtype).type().toString(), expected); in testZero() 67 MethodHandle mh = MethodHandles.zero(null); in testZeroNPE()
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/ |
D | ByteTest.java | 358 final Byte zero = new Byte((byte) 0); in test_compareToLjava_lang_Byte() local 363 assertTrue(zero.compareTo(zero) == 0); in test_compareToLjava_lang_Byte() 365 assertTrue(max.compareTo(zero) > 0); in test_compareToLjava_lang_Byte() 368 assertTrue(zero.compareTo(max) < 0); in test_compareToLjava_lang_Byte() 369 assertTrue(zero.compareTo(min) > 0); in test_compareToLjava_lang_Byte() 371 assertTrue(min.compareTo(zero) < 0); in test_compareToLjava_lang_Byte()
|
/libcore/tools/checkstyle/ |
D | jsr166-public-domain.pattern | 4 \* .*http://creativecommons\.org/publicdomain/zero/1\.0/
|
/libcore/ojluni/src/test/java/text/Collator/ |
D | CollatorTest.java | 70 String zero = "0000"; in prettify() local 77 result.append("\\u" + zero.substring(0, 4 - hex.length()) + hex); in prettify()
|
/libcore/ojluni/src/test/java/time/tck/java/time/format/ |
D | TCKOffsetPrinterParser.java | 506 String zero = null; in test_print_pattern_x() local 509 zero = "+00"; in test_print_pattern_x() 512 zero = "+0000"; in test_print_pattern_x() 515 zero = "+00:00"; in test_print_pattern_x() 518 zero = "+0000"; in test_print_pattern_x() 521 zero = "+00:00"; in test_print_pattern_x() 527 assertEquals(output, (expected.equals("Z") ? zero : expected)); in test_print_pattern_x()
|
/libcore/luni/src/test/java/libcore/java/lang/invoke/ |
D | MethodHandleCombinersTest.java | 627 assertEquals(false, (boolean) MethodHandles.zero(boolean.class).invokeExact()); in testZero() 628 assertEquals((byte) 0, (byte) MethodHandles.zero(byte.class).invokeExact()); in testZero() 629 assertEquals((char) 0, (char) MethodHandles.zero(char.class).invokeExact()); in testZero() 630 assertEquals((short) 0, (short) MethodHandles.zero(short.class).invokeExact()); in testZero() 631 assertEquals(0, (int) MethodHandles.zero(int.class).invokeExact()); in testZero() 632 assertEquals(0L, (long) MethodHandles.zero(long.class).invokeExact()); in testZero() 633 assertEquals(0.0f, (float) MethodHandles.zero(float.class).invokeExact()); in testZero() 634 assertEquals(0.0, (double) MethodHandles.zero(double.class).invokeExact()); in testZero() 635 assertEquals(null, MethodHandles.zero(Object.class).invokeExact()); in testZero() 636 assertEquals(null, (Integer) MethodHandles.zero(Integer.class).invokeExact()); in testZero() [all …]
|