Package com.wesabe.api.util.money

Examples of com.wesabe.api.util.money.Money.signum()


    }

    @Test
    public void shouldHaveASignOfZero() throws Exception {
      Money zeroDollars = new Money(decimal("0.00"), USD);
      assertEquals(0, zeroDollars.signum());
    }

    @Test
    public void shouldBeEqualToZeroDollars() throws Exception {
      Money zeroDollars = new Money(decimal("0.00"), USD);
View Full Code Here


  public static class Negative_One_Dollar {
    @Test
    public void shouldHaveASignOfNegativeOne() throws Exception {
      Money negativeOneDollar = new Money(decimal("-1.00"), USD);
      assertEquals(-1, negativeOneDollar.signum());
    }

    @Test
    public void shoudlHaveAnAbsoluteValueOfOneDollar() throws Exception {
      Money negativeOneDollar = new Money(decimal("-1.00"), USD);
View Full Code Here

    }

    @Test
    public void shouldHaveASignOfOne() throws Exception {
      Money oneDollar = new Money(decimal("1.00"), USD);
      assertEquals(1, oneDollar.signum());
    }

    @Test
    public void shouldBeEqualToOneDollar() throws Exception {
      Money oneDollar = new Money(decimal("1.00"), USD);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.