public static SqlColumnDeclaration Convert(PropertyInfoWithAttributes propertyInfoWithAttributes) { var nullableSqlType = ClrTypeToSqlTypeConverter.Convert(propertyInfoWithAttributes.PropertyInfo.PropertyType); var name = propertyInfoWithAttributes.PropertyInfo.Name; AddNecessaryAnnotations(nullableSqlType, propertyInfoWithAttributes); return(new SqlColumnDeclaration(name, nullableSqlType)); }
public void TestTranslate(Type type, bool canTranslate) { var canTranslateResult = ClrTypeToSqlTypeConverter.CanTranslateToSqlType(type); canTranslateResult.Should().Be(canTranslate); if (canTranslate) { Console.WriteLine(ClrTypeToSqlTypeConverter.Convert(type)); } }