public void test_prec1() { // System.err.println("0.04 " + REALdoubleAdapter.valueOf(0.04,INTlongAdapter.TWO) + " " + // REALdoubleAdapter.valueOf("0.04").precision()); // System.err.println(REALdoubleAdapter.formatDouble(1.04, INTlongAdapter.valueOf(3))); // System.err.println(REALdoubleAdapter.formatDouble(0.04, INTlongAdapter.valueOf(1))); // System.err.println(REALdoubleAdapter.formatDouble(0.04, INTlongAdapter.valueOf(3))); // System.err.println(REALdoubleAdapter.formatDouble(0.04, INTlongAdapter.valueOf(2))); // System.err.println(REALdoubleAdapter.formatDouble(0.04, // REALdoubleAdapter.INFINITE_PRECISION)); // System.err.println(REALdoubleAdapter.formatDouble(0.04, REALdoubleAdapter.DOUBLE_PRECISION)); assertEquals("0.04", REALdoubleAdapter.valueOf(0.04, INTlongAdapter.ONE).toString()); }
public void test_p12() { assertEquals(1, REALdoubleAdapter.valueOf("0.04").precision().intValue()); }
public void test_p11() { assertEquals(2, REALdoubleAdapter.valueOf("4.1").precision().intValue()); }
public void test_p1() { assertEquals(4, REALdoubleAdapter.valueOf("2000.").precision().intValue()); }