If you are trying to run unit test your queries, I highly recommend just setting up a test database and validating them with real data. Using IObjectSet<T>to replace the in-memory collection for your unit tests being tested is the idea of BAD. There are differences between how the linq query is executed under linq-to-objects, and how it is analyzed in the T-SQL command, namely, how the zeros are processed. For instance,
db.People.Where(p => p.AccountNum == variable);
linq-to-objects ( , IObjectSet<T> ), . , , , null, ,
WHERE [peopleTableAlias].[AccountNum] = @param1
, @param1 null, , IS NULL.
-, EAT , , DataAccess, , DAO, , , , , (, Rhino).
- , IObjectSet<T> EF4, , . - , , - .