Esempio n. 1
0
        public void ItShouldCacheMethodInfoByType()
        {
            var compiler = new TestSqlServerCompiler();

            var call1 = compiler.Call_FindCompilerMethodInfo(
                typeof(BasicCondition), "CompileBasicCondition"
                );

            var call2 = compiler.Call_FindCompilerMethodInfo(
                typeof(BasicCondition), "CompileBasicCondition"
                );

            Assert.Same(call1, call2);
        }
Esempio n. 2
0
        public void Return_Different_MethodInfo_WhenSame_Method_With_Different_GenericTypes()
        {
            var compiler = new TestSqlServerCompiler();

            var call1 = compiler.Call_FindCompilerMethodInfo(
                typeof(NestedCondition <Query>), "CompileNestedCondition"
                );

            var call2 = compiler.Call_FindCompilerMethodInfo(
                typeof(NestedCondition <Join>), "CompileNestedCondition"
                );

            Assert.NotSame(call1, call2);
        }