Update of /cvsroot/springnet/Spring.Net/test/Spring/Spring.Core.Tests/Util
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv27343/test/Spring/Spring.Core.Tests/Util
Modified Files:
ReflectionUtilsTests.cs
Log Message:
ReflectionUtils.getMostSpecificMethod() throws exception when handling Generic methods with the same parameter signature and different generic types
[SPRNET-722]
Index: ReflectionUtilsTests.cs
===================================================================
RCS file: /cvsroot/springnet/Spring.Net/test/Spring/Spring.Core.Tests/Util/ReflectionUtilsTests.cs,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** ReflectionUtilsTests.cs 8 Aug 2007 08:25:54 -0000 1.17
--- ReflectionUtilsTests.cs 20 Sep 2007 12:31:01 -0000 1.18
***************
*** 210,248 ****
[Test]
- [ExpectedException(typeof (ArgumentNullException))]
- public void GetMostSpecificMethodWithAllNulls()
- {
- ReflectionUtils.GetMostSpecificMethod(null, null);
- }
-
- [Test]
- public void GetMostSpecificMethodWithJustTargetTypeNull()
- {
- MethodInfo method = GetType().GetMethod("GetMostSpecificMethodWithJustTargetTypeNull");
- MethodInfo actual = ReflectionUtils.GetMostSpecificMethod(method, null);
- Assert.IsNotNull(actual);
- Assert.IsTrue(object.ReferenceEquals(method, actual));
- }
-
- [Test]
- public void GetMostSpecificMethodWithClassThatDoesntExplicitlyImplementInterfaceMethod()
- {
- MethodInfo method = typeof (IFoo).GetMethod("Spanglish");
- MethodInfo actual = ReflectionUtils.GetMostSpecificMethod(method, typeof (ReflectionUtilsObject));
- Assert.IsNotNull(actual);
- // make sure we got the method on the type, not just what we passed in
- Assert.IsFalse(object.ReferenceEquals(method, actual));
- }
-
- [Test]
- public void GetMostSpecificMethodWithClassThatDoesntHaveSuchAMethod()
- {
- MethodInfo method = GetType().GetMethod("GetMostSpecificMethodWithClassThatDoesntHaveSuchAMethod");
- MethodInfo actual = ReflectionUtils.GetMostSpecificMethod(method, typeof (ReflectionUtilsObject));
- Assert.IsNotNull(actual);
- Assert.IsTrue(object.ReferenceEquals(method, actual));
- }
-
- [Test]
public void GetSignature()
{
--- 210,213 ----
|