예제 #1
0
        public void Apply_DefaultAllowed()
        {
            var node = new SingleExpressionNode(CreateParseInfo(SingleExpressionNode.SupportedMethods[3].MakeGenericMethod(typeof(Cook))), null);

            node.Apply(QueryModel, ClauseGenerationContext);

            Assert.That(((SingleResultOperator)QueryModel.ResultOperators[0]).ReturnDefaultWhenEmpty, Is.True);
        }
예제 #2
0
        public void Apply_DefaultAllowed()
        {
            var node = new SingleExpressionNode(CreateParseInfo(ReflectionUtility.GetMethod(() => Queryable.SingleOrDefault <Cook> (null, null))), null);

            node.Apply(QueryModel, ClauseGenerationContext);

            Assert.That(((SingleResultOperator)QueryModel.ResultOperators[0]).ReturnDefaultWhenEmpty, Is.True);
        }