public void Get_Fields()
        {
            // arrange
            var conn = new Mock<DbConnection>();
            var restrictions = new [] { null, null, "tableName", null };
            conn.Setup(x => x.GetSchema("Columns", restrictions))
                .Returns(schema);
            var descriptor = new TableDescriptor(conn.Object);

            // act
            var fields = descriptor.GetFields("tableName");

            // assert
            AssertCorrectSchemaFields(fields);
        }
示例#2
0
 private SqlGenerator(TableDescriptor descriptor)
 {
     this.descriptor = descriptor;
 }