public class DecimalComparableQuantityTest {
@Test
public void divideOperationsTest() {
ComparableQuantity<Length> metre = Quantities.getQuantity(BigDecimal.TEN, SI.METRE);
ComparableQuantity<Time> time = Quantities.getQuantity(BigDecimal.TEN, SI.SECOND);
<BUG>ComparableQuantity<Speed> speed = metre.divide(QuantityOperations.of(time, Speed.class));
Assert.assertEquals(Integer.valueOf(speed.getValue().intValue()), Integer.valueOf(1));</BUG>
Assert.assertEquals(SI.METRES_PER_SECOND, speed.getUnit());
}
@Test(expected = ClassCastException.class)

public class DecimalComparableQuantityTest {
@Test
public void divideOperationsTest() {
ComparableQuantity<Length> metre = Quantities.getQuantity(BigDecimal.TEN, SI.METRE);
ComparableQuantity<Time> time = Quantities.getQuantity(BigDecimal.TEN, SI.SECOND);
ComparableQuantity<Speed> speed = metre.divide(time, Speed.class);
Assert.assertEquals(Integer.valueOf(speed.getValue().intValue()), Integer.valueOf(1));
Assert.assertEquals(SI.METRES_PER_SECOND, speed.getUnit());
}
@Test(expected = ClassCastException.class)
