/libcore/ojluni/src/test/java/lang/Math/ |
D | FusedMultiplyAddTests.java | 112 for (double[] testCase : testCases) { in testNonFiniteD() 113 testFusedMacCase(testCase[0], testCase[1], testCase[2], testCase[3]); in testNonFiniteD() 161 for (double[] testCase : testCases) { in testZeroesD() 162 testFusedMacCase(testCase[0], testCase[1], testCase[2], testCase[3]); in testZeroesD() 212 for (double[] testCase : testCases) { in testSimpleD() 213 testFusedMacCase(testCase[0], testCase[1], testCase[2], testCase[3]); in testSimpleD() 260 for (float[] testCase : testCases) { in testNonFiniteF() 261 testFusedMacCase(testCase[0], testCase[1], testCase[2], testCase[3]); in testNonFiniteF() 305 for (float[] testCase : testCases) { in testZeroesF() 306 testFusedMacCase(testCase[0], testCase[1], testCase[2], testCase[3]); in testZeroesF() [all …]
|
D | WorstCaseTests.java | 98 for (double[] testCase : testCases) { in testWorstExp() 99 testExpCase(testCase[0], testCase[1]); in testWorstExp() 126 for (double[] testCase : testCases) { in testWorstLog() 127 testLogCase(testCase[0], testCase[1]); in testWorstLog() 155 for (double[] testCase : testCases) { in testWorstSin() 156 testSinCase(testCase[0], testCase[1]); in testWorstSin() 183 for (double[] testCase : testCases) { in testWorstAsin() 184 testAsinCase(testCase[0], testCase[1]); in testWorstAsin() 212 for (double[] testCase : testCases) { in testWorstCos() 213 testCosCase(testCase[0], testCase[1]); in testWorstCos() [all …]
|
D | AbsTests.java | 50 for(var testCase : testCases) { in testInRangeIntAbs() 51 testIntAbs(Math::abs, testCase[0], testCase[1]); in testInRangeIntAbs() 52 testIntAbs(Math::absExact, testCase[0], testCase[1]); in testInRangeIntAbs() 90 for(var testCase : testCases) { in testInRangeLongAbs() 91 testLongAbs(Math::abs, testCase[0], testCase[1]); in testInRangeLongAbs() 92 testLongAbs(Math::absExact, testCase[0], testCase[1]); in testInRangeLongAbs()
|
D | IeeeRecommendedTests.java | 424 for (float[] testCase : testCases) { in testFloatNextAfter() 425 testNextAfterCase(testCase[0], testCase[1], testCase[2]); in testFloatNextAfter() 492 for (double[] testCase : testCases) { in testDoubleNextAfter() 493 testNextAfterCase(testCase[0], testCase[1], testCase[2]); in testDoubleNextAfter() 524 for (float[] testCase : testCases) { in testFloatNextUp() 526 testCase[0], Math.nextUp(testCase[0]), testCase[1]); in testFloatNextUp() 529 testCase[0], StrictMath.nextUp(testCase[0]), testCase[1]); in testFloatNextUp() 558 for (double[] testCase : testCases) { in testDoubleNextUp() 560 testCase[0], Math.nextUp(testCase[0]), testCase[1]); in testDoubleNextUp() 563 testCase[0], StrictMath.nextUp(testCase[0]), testCase[1]); in testDoubleNextUp() [all …]
|
D | Atan2Tests.java | 52 for (double[] testCase : testCases) { in testAtan2() 53 testAtan2Case(testCase[0], testCase[1], testCase[2]); in testAtan2()
|
D | RoundTests.java | 46 for (double[] testCase : testCases) { in testNearDoubleHalfCases() 47 testNearHalfCases(testCase[0], (long) testCase[1]); in testNearDoubleHalfCases() 68 for (float[] testCase : testCases) { in testNearFloatHalfCases() 69 testNearHalfCases(testCase[0], (int) testCase[1]); in testNearFloatHalfCases()
|
D | ExpCornerCaseTests.java | 46 for (double[] testCase : testCases) { in testExpCornerCases() 47 testExp(testCase[0], testCase[1]); in testExpCornerCases()
|
D | HyperbolicTests.java | 238 for (double[] testCase : testCases) { in testSinh() 239 testSinhCaseWithUlpDiff(testCase[0], testCase[1], 3.0); in testSinh() 587 for (double[] testCase : testCases) { in testCosh() 588 testCoshCaseWithUlpDiff(testCase[0], testCase[1], 3.0); in testCosh() 934 for (double[] testCase : testCases) { in testTanh() 935 testTanhCaseWithUlpDiff(testCase[0], testCase[1], 3.0); in testTanh()
|
D | CeilAndFloorTests.java | 176 for (double[] testCase : testCases) { in roundingTests() 177 testCeilCase(testCase[0], testCase[1]); in roundingTests() 178 testFloorCase(-testCase[0], -testCase[1]); in roundingTests()
|
D | Rint.java | 99 for (double[] testCase : testCases) { in testRint() 100 testRintCase(testCase[0], testCase[1]); in testRint()
|
D | TanTests.java | 172 for (double[] testCase : testCases) { in testTan() 173 testTanCase(testCase[0], testCase[1], testCase[2]); in testTan()
|
/libcore/luni/src/test/java/libcore/java/math/ |
D | CSVTest.java | 51 String[] testCase = line.split(","); in TestCSVInputs() local 52 runTest(testCase); in TestCSVInputs() 65 protected void runTest(String[] testCase) throws Exception { in runTest() argument 66 String function = testCase[0]; in runTest() 67 double expectedOutput = Double.parseDouble(testCase[1]); in runTest() 68 double input = Double.parseDouble(testCase[2]); in runTest() 71 double input2 = Double.parseDouble(testCase[3]); in runTest() 72 if (testCase.length > 4) { in runTest() 73 extra = testCase[4]; in runTest() 77 if (testCase.length > 3) { in runTest() [all …]
|
/libcore/ojluni/src/test/java/math/BigDecimal/ |
D | PowTests.java | 63 for(BigDecimal[] testCase: testCases) { in zeroAndOneTests() 64 int exponent = testCase[1].intValueExact(); in zeroAndOneTests() 68 result = testCase[0].pow(exponent); in zeroAndOneTests() 69 Assert.assertEquals(result, testCase[2], "Unexpected result while raising " + in zeroAndOneTests() 70 testCase[0] + in zeroAndOneTests() 72 testCase[2] + ", got " + result + "."); in zeroAndOneTests() 74 if (testCase[2] != null) { in zeroAndOneTests() 75 Assert.fail("Unexpected exception while raising " + testCase[0] + in zeroAndOneTests()
|
D | ToPlainStringTests.java | 79 for(String[] testCase: testCases) { in testToPlainString() 80 BigDecimal bd = new BigDecimal(testCase[0]); in testToPlainString() 84 Assert.assertEquals(s, testCase[1], in testToPlainString() 87 bd = new BigDecimal("-"+testCase[0]); in testToPlainString() 89 Assert.assertFalse(bd.signum()!=0 && !s.equals("-"+testCase[1]), in testToPlainString()
|
D | IntegralDivisionTests.java | 62 for(BigDecimal [] testCase: moreTestCases) { in dividetoIntegralValueTests() 63 BigDecimal quotient = testCase[0].divideToIntegralValue(testCase[1]); in dividetoIntegralValueTests() 64 Assert.assertEquals(quotient, testCase[2], in dividetoIntegralValueTests() 65 "dividend = " + testCase[0] + " scale = " + testCase[0].scale() + in dividetoIntegralValueTests() 66 " divisor = " + testCase[1] + " scale = " + testCase[1].scale() + in dividetoIntegralValueTests() 68 " expected = " + testCase[2] + " scale = " + testCase[2].scale()); in dividetoIntegralValueTests()
|
D | NegateTests.java | 51 for (BigDecimal [] testCase : testCases) { in negateTest() 53 BigDecimal bd = testCase[0]; in negateTest() 56 BigDecimal expected = testCase[1]; in negateTest()
|
D | CompareToTests.java | 87 for (BigDecimal[] testCase : testCases) { in compareToTests() 88 BigDecimal a = testCase[0]; in compareToTests() 90 BigDecimal b = testCase[1]; in compareToTests() 92 int expected = testCase[2].intValue(); in compareToTests()
|
D | IntValueExactTests.java | 76 for (var testCase : successCases.entrySet()) { in intValueExactSuccessful() 77 BigDecimal bd = testCase.getKey(); in intValueExactSuccessful() 78 int expected = testCase.getValue(); in intValueExactSuccessful()
|
/libcore/luni/src/test/java/libcore/libcore/util/ |
D | HexEncodingTest.java | 43 for (Object[] testCase : testCases) { in testEncodeByte() 44 Number toEncode = (Number) testCase[0]; in testEncodeByte() 45 String expected = (String) testCase[1]; in testEncodeByte() 60 for (Object[] testCase : testCases) { in testEncodeBytes() 61 byte[] bytes = (byte[]) testCase[0]; in testEncodeBytes() 62 String encodedLower = lower((String) testCase[1]); in testEncodeBytes() 63 String encodedUpper = upper((String) testCase[1]); in testEncodeBytes()
|
/libcore/ojluni/src/test/java/lang/StrictMath/ |
D | HyperbolicTests.java | 149 for (double[] testCase : testCases) { in testSinh() 150 testSinhCase(testCase[0], testCase[1]); in testSinh() 189 for (double[] testCase : testCases) { in testCosh() 190 testCoshCase(testCase[0], testCase[1]); in testCosh() 257 for (double[] testCase : testCases) { in testTanh() 258 testTanhCase(testCase[0], testCase[1]); in testTanh()
|
D | PowTests.java | 272 for (double[] testCase : testCases) { in testPow() 273 testPowCase(testCase[0], testCase[1], testCase[2]); in testPow()
|
D | ExpTests.java | 75 for (double[] testCase : testCases) { in testExp() 76 testExpCase(testCase[0], testCase[1]); in testExp()
|
/libcore/ojluni/src/test/java/lang/Double/ |
D | ParseHexFloatingPointTest.java | 57 static void testCase(String input, double expected) { in testCase() method in ParseHexFloatingPointTest 148 testCase(input, 3.0); in testDouble() 151 testCase(input, 3.0); in testDouble() 175 testCase("0x0.0p"+Long.toString(bigExponents[i]) , 0.0); in testDouble() 181 testCase("0x10000.0p"+Long.toString(exponent) , in testDouble() 190 testCase("0x"+Long.toHexString(signif)+"p0", signif); in testDouble() 247 testCase(testCases[i].s,testCases[i].d); in testDouble() 258 testCase(Double.toHexString(d), d); in testRandomDoubles() 314 testCase(s, expected); in significandAlignmentTests()
|
/libcore/ojluni/src/test/java/math/BigInteger/ |
D | CompareToTests.java | 99 for (BigInteger[] testCase : testCases) { in compareToTests() 100 BigInteger a = testCase[0]; in compareToTests() 102 BigInteger b = testCase[1]; in compareToTests() 104 int expected = testCase[2].intValue(); in compareToTests()
|
/libcore/dom/src/test/java/org/w3c/domts/ |
D | DOMErrorMonitor.java | 57 public void assertLowerSeverity(DOMTestCase testCase, String id, int severity) { in assertLowerSeverity() argument 62 testCase.fail(id + error.getMessage()); in assertLowerSeverity()
|