コード例 #1
0
        public void FactoryOrBuilderMethodsDontCount(string methodName, int expectedProblemCount)
        {
            var rule = new MethodCallRule();

            rule.Check(AssemblyReader.GetMethodByName(typeof(ClassF), methodName));
            Assert.That(rule.Problems.Count, Is.EqualTo(expectedProblemCount));
        }
コード例 #2
0
        public void CannotInvokeConcreteMethods(string methodName, int expectedProblemCount)
        {
            var rule = new MethodCallRule();

            rule.Check(AssemblyReader.GetMethodByName(typeof(ClassF), methodName));
            Assert.That(rule.Problems.Count, Is.EqualTo(expectedProblemCount));
        }