@Test void getSqlDropColumnDefault() { EntityType entityType = when(mock(EntityType.class).getId()).thenReturn("entity").getMock(); when(entityType.getId()).thenReturn("entityTypeId"); Attribute attr = when(mock(Attribute.class).getName()).thenReturn("attr").getMock(); when(attr.getIdentifier()).thenReturn("attrId"); assertEquals( "ALTER TABLE \"entityTypeId#c34894ba\" ALTER COLUMN \"attr\" DROP DEFAULT", PostgreSqlQueryGenerator.getSqlDropColumnDefault(entityType, attr)); }
static String getSqlDropColumnDefault(EntityType entityType, Attribute attr) { return "ALTER TABLE " + getTableName(entityType) + " ALTER COLUMN " + getColumnName(attr) + " DROP DEFAULT"; }
PostgreSqlQueryGenerator { static String getSqlDropColumnDefault(EntityType entityType, Attribute attr) { return "ALTER TABLE " + getTableName(entityType) + " ALTER COLUMN " + getColumnName(attr) + " DROP DEFAULT"; } }
PostgreSqlQueryGenerator { static String getSqlDropColumnDefault(EntityType entityType, Attribute attr) { return "ALTER TABLE " + getTableName(entityType) + " ALTER COLUMN " + getColumnName(attr) + " DROP DEFAULT"; } private  PostgreSqlQueryGenerator(); }
PostgreSqlQueryGenerator { static String getSqlDropColumnDefault(EntityType entityType, Attribute attr) { return "ALTER TABLE " + getTableName(entityType) + " ALTER COLUMN " + getColumnName(attr) + " DROP DEFAULT"; } private  PostgreSqlQueryGenerator();  }
PostgreSqlQueryGenerator { static String getSqlDropColumnDefault(EntityType entityType, Attribute attr) { return "ALTER TABLE " + getTableName(entityType) + " ALTER COLUMN " + getColumnName(attr) + " DROP DEFAULT"; } private  PostgreSqlQueryGenerator();   }