()
| 100 | } |
| 101 | |
| 102 | @Test |
| 103 | public void testFloats() |
| 104 | { |
| 105 | IonFloat value = (IonFloat) oneValue("1.0e0"); |
| 106 | assertSame(IonType.FLOAT, value.getType()); |
| 107 | assertFalse(value.isNullValue()); |
| 108 | assertArrayEquals(new String[0], value.getTypeAnnotations()); |
| 109 | assertEquals(1.0F, value.floatValue()); |
| 110 | assertEquals(1.0D, value.doubleValue()); |
| 111 | |
| 112 | // TODO more... |
| 113 | |
| 114 | value = (IonFloat) oneValue("a::1.0e0"); |
| 115 | assertFalse(value.isNullValue()); |
| 116 | checkAnnotation("a", value); |
| 117 | |
| 118 | // Ensure that annotation makes it through value mods |
| 119 | modifyFloat(value); |
| 120 | checkAnnotation("a", value); |
| 121 | |
| 122 | // TODO test BigDecimal |
| 123 | } |
| 124 | |
| 125 | @Test |
| 126 | public void testParsingSpecialFloats() |
nothing calls this directly
no test coverage detected