unitsofmeasurement / uom-systems

Units of Measurement Systems
http://www.uom.systems
Other
36 stars 17 forks source link

UCUMFormat might not identify Prefixes when inspecting UnitConverters #146

Closed andi-huber closed 5 years ago

andi-huber commented 5 years ago

These tests are supposed to succeed:

@Test
public void testKiloGram() {
    Unit<Mass> m1 = KILO(GRAM);
    assertEquals("kg", FORMAT_PRINT.format(m1));
}

@Test
public void testMegaGram() {
    Unit<Mass> m1 = MEGA(GRAM);
    assertEquals("t", FORMAT_PRINT.format(TONNE));
    assertEquals("Mg", FORMAT_PRINT.format(m1));
}

@Test
public void testMegaTonne() {
    Unit<Mass> m1 = MEGA(TONNE);
    assertEquals("Mt", FORMAT_PRINT.format(m1));
}

@Test
public void testNanoGram() {
    Unit<Mass> m1 = NANO(GRAM);
    assertEquals("ng", FORMAT_PRINT.format(m1));
}
keilw commented 5 years ago

Thanks, if no other big issues come up, we may be able to release 2.0 in the course of this week.