开发者

database setup for Unit testing Linq to Sql, where database have relationships

开发者 https://www.devze.com 2022-12-20 05:15 出处:网络
I google around unit testing LINQ to SQL and 开发者_运维问答people are using MockDatabase class where we have list and add data to those Lists.

I google around unit testing LINQ to SQL and 开发者_运维问答people are using MockDatabase class where we have list and add data to those Lists.

This will fit in the scenarios where we dont have relationships. I am behind using some data or mdf file in the unit test project which will have the same structure as like my actual database with all relationships and LINQ-to-SQL dml statements will be thoroughly tested.

Any idea what kind of mock database can i use???

0

精彩评论

暂无评论...
验证码 换一张
取 消