Releases: Apps72/DbMocker
Releases · Apps72/DbMocker
Add a MockColumn class to manage the column type
- Add a
MockColumn
class to manage the column type. See example using "typed columns" above.
Sample using a MockTable.WithColumns() typed columns. In this case, columns are defined using a tuple (ColumnName, ColumnType).
conn.Mocks
.WhenAny()
.ReturnsTable(MockTable.WithColumns(("ID", typeof(int?)),
("Name", typeof(string)))
.AddRow(null, "Scott")
.AddRow(2, "Bill"));
- Breaking change: to allow typed MockColumn, the property
MockTable.Columns
is now of type MockColumn[] (previously string[]).
Packages: https://www.nuget.org/packages/DbMocker