我不确定我做错了什么,但在测试中运行时,这行代码永远不会返回(似乎导致失控过程):
var discountMemberCustomer = (from customer in Mocks.Query<Customer>()
where customer.IsDiscountMember &&
customer.OrderCount == 13 &&
customer.LifetimeCustomerValue == 5555m
select customer).First();
据我所知,我正在关注这些例子:http://www.clariusconsulting.net/blogs/kzu/archive/2009/08/13/164978.aspx
答案 0 :(得分:2)
尝试“设置”IsDiscountMember
:
...
where customer.IsDiscountMember == true &&
...
答案 1 :(得分:0)