Currently, entityType.GetDefaultMappings() should only be used in a FromSql context. Elsewhere, if the entity type is not mapped to a table, a view, a SqlQuery or a function, an exception should be thrown.
Also, add more tests (particularly negative cases) for FromSql and ToSqlQuery.
Currently,
entityType.GetDefaultMappings()should only be used in aFromSqlcontext. Elsewhere, if the entity type is not mapped to a table, a view, a SqlQuery or a function, an exception should be thrown.Also, add more tests (particularly negative cases) for
FromSqlandToSqlQuery.