コード例 #1
0
 @Test
 public void isDrawable_isCorrect() throws Exception {
   Assert.assertTrue(drawableBreakDown.isDrawable());
   Assert.assertFalse(notDrawableBreakDown.isDrawable());
 }
コード例 #2
0
 @Test
 public void getAngle_isCorrect() throws Exception {
   Assert.assertEquals(drawableBreakDown.getAngle(), 38.28204f, 0.00001);
   Assert.assertEquals(notDrawableBreakDown.getAngle(), 0.03564f, 0.00001);
 }
コード例 #3
0
 @Test
 public void getAllocationPercentage_isCorrect() throws Exception {
   Assert.assertEquals(drawableBreakDown.getAllocationPercentage(), "10.63%");
   Assert.assertEquals(notDrawableBreakDown.getAllocationPercentage(), "0.01%");
 }
コード例 #4
0
 @Test
 public void getPLPercentage_isCorrect() throws Exception {
   Assert.assertEquals(drawableBreakDown.getPLPercentage(), "23.29");
   Assert.assertEquals(notDrawableBreakDown.getPLPercentage(), "0.03");
 }
コード例 #5
0
 @Test
 public void getName_isCorrect() throws Exception {
   Assert.assertEquals(drawableBreakDown.getInstrumentName(), "ADIDAS");
   Assert.assertEquals(notDrawableBreakDown.getInstrumentName(), "AUDJPY");
 }