Util { public static String toColumnName(String attributeName) { return camelCaseToLowerUnderscore(attributeName); }  static String getMultiplicityAbbreviation(Perspective p); static String lowerFirst(String s); static String upperFirst(String s); static String toClassSimpleName(String name); static String toJavaIdentifier(String name); static String toJavaConstantIdentifier(String name); static String camelCaseToLowerUnderscore(String s); static String toTableName(String className); static String toTableIdName(String className); static String toColumnName(String attributeName); static ModeledDomain getModeledDomain(Domains domains, String name); static ModeledDomain getModeledDomain(InputStream is, String domainName); static String getPackage(String className); static String getSimpleClassName(String className); static List<Class> getClasses(ModeledDomain domain);  }
@Test public void testToColumnName() { assertEquals("a", toColumnName("a")); assertEquals("ab", toColumnName("ab")); assertEquals("a_b", toColumnName("aB")); assertEquals("a_b", toColumnName("a_b")); assertEquals("a_b", toColumnName("a b")); assertEquals("a_b_c", toColumnName("a b c")); assertEquals("a_b_two", toColumnName("A B two")); }