Home
last modified time | relevance | path

Searched refs:ArithmeticException (Results 1 – 25 of 74) sorted by relevance

123

/libcore/ojluni/src/test/java/lang/Math/
DDivModTests.java78 …testIntFloorDivMod(4, 0, new ArithmeticException(), new ArithmeticException()); // Should throw Ar… in testIntFloorDivMod()
158 } catch (ArithmeticException ae) { in testIntFloorMod()
170 …testLongFloorDivMod(4L, 0L, new ArithmeticException(), new ArithmeticException()); // Should throw… in testLongFloorDivMod()
267 } catch (ArithmeticException ae) { in testLongFloorMod()
279 …testLongIntFloorDivMod(4L, 0, new ArithmeticException(), new ArithmeticException()); // Should thr… in testLongIntFloorDivMod()
375 } catch (ArithmeticException ae) { in testLongIntFloorMod()
391 } catch (ArithmeticException ae) { in doFloorDiv()
405 } catch (ArithmeticException ae) { in doFloorDiv()
419 } catch (ArithmeticException ae) { in doFloorDiv()
433 } catch (ArithmeticException ae) { in doFloorMod()
[all …]
DExactArithTests.java109 } catch (ArithmeticException ex) { in testIntegerExact()
124 } catch (ArithmeticException ex) { in testIntegerExact()
138 } catch (ArithmeticException ex) { in testIntegerExact()
151 } catch (ArithmeticException e) { in testIntegerExact()
158 } catch (ArithmeticException e) { in testIntegerExact()
177 } catch (ArithmeticException ex) { in testIntegerExact()
190 } catch (ArithmeticException e) { in testIntegerExact()
211 } catch (ArithmeticException ex) { in testIntegerExact()
224 } catch (ArithmeticException e) { in testIntegerExact()
244 } catch (ArithmeticException ex) { in testIntegerExact()
[all …]
DAbsTests.java62 assertThrows(ArithmeticException.class, () -> Math.absExact(Integer.MIN_VALUE)); in testIntMinValue()
102 assertThrows(ArithmeticException.class, () -> Math.absExact(Long.MIN_VALUE)); in testLongMinValue()
/libcore/luni/src/test/java/libcore/java/lang/
DMathTest.java50 } catch (ArithmeticException e) { in testAddExactI()
61 } catch (ArithmeticException e) { in testSubtractExactI()
73 } catch (ArithmeticException e) { in testMultiplyExactI()
84 } catch (ArithmeticException e) { in testIncrementExactI()
95 } catch (ArithmeticException e) { in testDecrementExactI()
106 } catch (ArithmeticException e) { in testNegateExactI()
139 } catch (ArithmeticException e) { in testAddExactL()
150 } catch (ArithmeticException e) { in testSubtractExactL()
161 } catch (ArithmeticException e) { in testMultiplyExactL()
172 } catch (ArithmeticException e) { in testIncrementExactL()
[all …]
DStrictMathTest.java47 } catch (ArithmeticException e) { in testAddExactI()
58 } catch (ArithmeticException e) { in testSubtractExactI()
70 } catch (ArithmeticException e) { in testMultiplyExactI()
100 } catch (ArithmeticException e) { in testAddExactL()
111 } catch (ArithmeticException e) { in testSubtractExactL()
122 } catch (ArithmeticException e) { in testMultiplyExactL()
133 } catch (ArithmeticException e) { in testToIntExactL()
164 } catch (ArithmeticException e) { in testFloorDivI()
179 } catch (ArithmeticException e) { in testFloorModI()
210 } catch (ArithmeticException e) { in testFloorDivL()
[all …]
/libcore/luni/src/test/java/libcore/java/math/
DOldBigDecimalConvertTest.java37 } catch (java.lang.ArithmeticException ae) { in test_IntValueExactNeg()
48 } catch (java.lang.ArithmeticException ae) { in test_IntValueExactPos()
58 } catch (java.lang.ArithmeticException ae) { in test_IntValueExactFloatNeg()
69 } catch (java.lang.ArithmeticException ae) { in test_IntValueExactFloatPos()
94 } catch (java.lang.ArithmeticException ae) { in test_LongValueExactNeg()
105 } catch (java.lang.ArithmeticException ae) { in test_LongValueExactPos()
115 } catch (java.lang.ArithmeticException ae) { in test_LongValueExactFloatNeg()
130 } catch (java.lang.ArithmeticException ae) { in test_LongValueExactFloatPos()
180 } catch (java.lang.ArithmeticException ae) { in test_ByteValueExactDoubleMax()
191 } catch (java.lang.ArithmeticException ae) { in test_ByteValueExactDoubleMin()
[all …]
DBigIntegerTest.java236 } catch (ArithmeticException e) { in test_byteValueExact()
244 } catch (ArithmeticException e) {} in test_byteValueExact()
248 } catch (ArithmeticException e) {} in test_byteValueExact()
257 } catch (ArithmeticException e) { in test_shortValueExact()
265 } catch (ArithmeticException e) {} in test_shortValueExact()
269 } catch (ArithmeticException e) {} in test_shortValueExact()
278 } catch (ArithmeticException e) { in test_intValueExact()
286 } catch (ArithmeticException e) {} in test_intValueExact()
290 } catch (ArithmeticException e) {} in test_intValueExact()
302 } catch (ArithmeticException e) { in test_longValueExact()
[all …]
DOldBigDecimalScaleOperationsTest.java40 } catch (ArithmeticException expected) { in testMovePointRightEx()
50 } catch (ArithmeticException expected) { in testMovePointRightEx2()
68 } catch (ArithmeticException expected) { in testScaleByPowerOfTenEx()
74 } catch (ArithmeticException expected) { in testScaleByPowerOfTenEx()
DOldBigDecimalArithmeticTest.java100 } catch (ArithmeticException e) { in testPowNonTrivial()
106 } catch (ArithmeticException e) { in testPowNonTrivial()
147 } catch (ArithmeticException e) { in testPowMathContextNonTrivial()
161 } catch (ArithmeticException e) { in testPowMathContextNonTrivial()
170 } catch (ArithmeticException e) { in testPowMathContextNonTrivial()
211 } catch (ArithmeticException e) { in testDivideINonTrivial()
236 } catch (ArithmeticException e) { in testDivideIINonTrivial()
268 } catch (ArithmeticException e) { in testDivideScaleRoundingModeNonTrivial()
316 } catch (ArithmeticException e) { in testDivideMathContextNonTrivial()
335 } catch (ArithmeticException e) { in testDivideToIntegralValueByZero()
[all …]
DOldBigDecimalConstructorsTest.java100 } catch (ArithmeticException e) { in testConstrBigIntegerMathContext()
106 } catch (ArithmeticException e) { in testConstrBigIntegerMathContext()
187 } catch (ArithmeticException e) { in testConstrBigIntegerScaleMathContext()
193 } catch (ArithmeticException e) { in testConstrBigIntegerScaleMathContext()
247 } catch (ArithmeticException e) { in testConstrBigIntegerScaleMathContext()
253 } catch (ArithmeticException e) { in testConstrBigIntegerScaleMathContext()
356 } catch (ArithmeticException e) { in testConstrCharIntIntMathContext()
362 } catch (ArithmeticException e) { in testConstrCharIntIntMathContext()
418 } catch (ArithmeticException e) { in testConstrCharMathContext()
424 } catch (ArithmeticException e) { in testConstrCharMathContext()
[all …]
DOldBigIntegerDivideTest.java42 } catch (ArithmeticException e) { in testCase21byZero()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/lang/
DArithmeticExceptionTest.java28 ArithmeticException e = new ArithmeticException(); in test_Constructor()
37 ArithmeticException e = new ArithmeticException("fixture"); in test_ConstructorLjava_lang_String()
/libcore/ojluni/src/test/java/lang/StrictMath/
DExactArithTests.java82 } catch (ArithmeticException ex) { in testIntegerExact()
97 } catch (ArithmeticException ex) { in testIntegerExact()
111 } catch (ArithmeticException ex) { in testIntegerExact()
127 } catch (ArithmeticException ex) { in testIntegerExact()
143 } catch (ArithmeticException ex) { in testIntegerExact()
159 } catch (ArithmeticException ex) { in testIntegerExact()
228 } catch (ArithmeticException ex) { in testLongExact()
239 } catch (ArithmeticException ex) { in testLongExact()
250 } catch (ArithmeticException ex) { in testLongExact()
261 } catch (ArithmeticException ex) { in testLongExact()
[all …]
/libcore/ojluni/src/test/java/math/BigInteger/
DLargeValueExceptions.java84 @Test(expectedExceptions=ArithmeticException.class,enabled=false)
93 @Test(expectedExceptions=ArithmeticException.class,enabled=false)
129 @Test(expectedExceptions=ArithmeticException.class,enabled=false)
147 @Test(expectedExceptions=ArithmeticException.class,enabled=false)
164 @Test(expectedExceptions=ArithmeticException.class)
169 @Test(expectedExceptions=ArithmeticException.class)
177 @Test(expectedExceptions=ArithmeticException.class)
185 @Test(expectedExceptions=ArithmeticException.class,enabled=false)
DTestValueExact.java62 } catch(ArithmeticException ae) { in testLongValueExact()
92 } catch(ArithmeticException ae) { in testIntValueExact()
126 } catch(ArithmeticException ae) { in testShortValueExact()
164 } catch(ArithmeticException ae) { in testByteValueExact()
DDoubleValueOverflow.java43 } catch (ArithmeticException e) { in main()
/libcore/ojluni/src/main/java/java/lang/
DArithmeticException.java40 public class ArithmeticException extends RuntimeException { class
48 public ArithmeticException() { in ArithmeticException() method in ArithmeticException
58 public ArithmeticException(String s) { in ArithmeticException() method in ArithmeticException
DMath.java1059 throw new ArithmeticException("integer overflow"); in addExact()
1079 throw new ArithmeticException("long overflow"); in addExact()
1100 throw new ArithmeticException("integer overflow"); in subtractExact()
1121 throw new ArithmeticException("long overflow"); in subtractExact()
1140 throw new ArithmeticException("integer overflow"); in multiplyExact()
1180 throw new ArithmeticException("long overflow"); in multiplyExact()
1213 throw new ArithmeticException("integer overflow"); in divideExact()
1243 throw new ArithmeticException("long overflow"); in divideExact()
1280 throw new ArithmeticException("integer overflow"); in floorDivExact()
1317 throw new ArithmeticException("long overflow"); in floorDivExact()
[all …]
/libcore/ojluni/src/test/java/math/BigDecimal/
DDivideTests.java49 throw new ArithmeticException("Division undefined"); // NaN in anotherDivide()
50 throw new ArithmeticException("Division by zero"); in anotherDivide()
120 throw new ArithmeticException("Non terminating decimal expansion"); in anotherDivide()
153 } catch (ArithmeticException e) { in powersOf2and5()
160 } catch (ArithmeticException e) { in powersOf2and5()
167 } catch (ArithmeticException e) { in powersOf2and5()
199 catch (ArithmeticException e) { in nonTerminating()
361 } catch (ArithmeticException e) { in divideByOneTests()
370 } catch (ArithmeticException e) { in divideByOneTests()
DAddTests.java94 } catch(ArithmeticException ae) { in addWithoutException()
234 } catch (ArithmeticException ae) { in roundAway0()
279 } catch (ArithmeticException ae) { in arithmeticExceptionTest()
DRoundingTests.java48 } catch(ArithmeticException e) { in roundingTests()
/libcore/ojluni/src/test/java/time/tck/java/time/
DTCKDuration.java161 @Test(expectedExceptions=ArithmeticException.class)
255 @Test(expectedExceptions=ArithmeticException.class)
260 @Test(expectedExceptions=ArithmeticException.class)
289 @Test(expectedExceptions=ArithmeticException.class)
294 @Test(expectedExceptions=ArithmeticException.class)
323 @Test(expectedExceptions=ArithmeticException.class)
328 @Test(expectedExceptions=ArithmeticException.class)
415 @Test(dataProvider="OfTemporalUnitOutOfRange", expectedExceptions=ArithmeticException.class)
471 @Test(expectedExceptions = ArithmeticException.class)
1122 @Test(expectedExceptions=ArithmeticException.class)
[all …]
DTCKPeriod.java194 @Test(expectedExceptions = ArithmeticException.class)
689 @Test(expectedExceptions=ArithmeticException.class)
695 @Test(expectedExceptions=ArithmeticException.class)
717 @Test(expectedExceptions=ArithmeticException.class)
723 @Test(expectedExceptions=ArithmeticException.class)
745 @Test(expectedExceptions=ArithmeticException.class)
751 @Test(expectedExceptions=ArithmeticException.class)
834 @Test(expectedExceptions=ArithmeticException.class)
840 @Test(expectedExceptions=ArithmeticException.class)
862 @Test(expectedExceptions=ArithmeticException.class)
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/math/
DBigIntegerTest.java380 } catch (ArithmeticException e) { in test_modInverseLjava_math_BigInteger()
401 } catch (ArithmeticException e) { in test_modInverseLjava_math_BigInteger()
569 } catch (ArithmeticException e) { in test_divideLjava_math_BigInteger()
575 } catch (ArithmeticException e) { in test_divideLjava_math_BigInteger()
581 } catch (ArithmeticException e) { in test_divideLjava_math_BigInteger()
587 } catch (ArithmeticException e) { in test_divideLjava_math_BigInteger()
598 } catch (ArithmeticException e) { in test_remainderLjava_math_BigInteger()
604 } catch (ArithmeticException e) { in test_remainderLjava_math_BigInteger()
610 } catch (ArithmeticException e) { in test_remainderLjava_math_BigInteger()
616 } catch (ArithmeticException e) { in test_remainderLjava_math_BigInteger()
[all …]
DBigIntegerModPowTest.java47 } catch (ArithmeticException e) { in testModPowException()
53 } catch (ArithmeticException e) { in testModPowException()
140 } catch (ArithmeticException e) { in testmodInverseException()
157 } catch (ArithmeticException e) { in testmodInverseNonInvertible()

123