title: Mockito and Assertions - two same BigDecimals... not equal
body: <p>I have a small problem with Assertion, or maybe just with BigDecimal.</p>
  
  <p>My JUnit test is throwing an error while using <code>assertEquals(Object expected, Object actual)</code>:</p>
  
  <pre><code>java.lang.AssertionError: expected:&lt;10&gt; but was:&lt;10.000000000&gt;
  </code></pre>
  
  <p>expected is created via:</p>
  
  <pre><code>BigDecimal expected = MathHelper.getDecimal(10);
  </code></pre>
  
  <p>The <code>getDecimal</code> method in <code>MathHelper</code> looks like this:</p>
  
  <pre><code>public static final BigDecimal getDecimal(long value) {
      return BigDecimal.valueOf(value);
  }
  </code></pre>
  
  <p>The <code>actual</code> is a <code>private BigDecimal count</code> and it's getter method is a classic getter:</p>
  
  <pre><code>public BigDecimal getCount() {
      return count;
  }
  </code></pre>
  
  <p>I have absolutely no idea what is going on here...</p>