Imported Upstream version 3.12.0

Former-commit-id: cf92446697332992ec36726e78eb8703e1f259d7
This commit is contained in:
Jo Shields
2015-01-13 10:44:36 +00:00
parent 8b9b85e7f5
commit 181b81b4a4
659 changed files with 12743 additions and 16300 deletions

View File

@ -42,7 +42,6 @@ namespace MonoCasTests.System.Reflection {
public class AssemblyNameCas {
private MonoTests.System.Reflection.AssemblyNameTest ant;
private AssemblyName main;
[TestFixtureSetUp]
public void FixtureSetUp ()

View File

@ -73,6 +73,8 @@ namespace MonoTests.System.Reflection
{
}
// Disable this warning, as the purpose of this struct is to poke at the internal via reflection
#pragma warning disable 649
class FieldInvokeMatrix
{
public Byte field_Byte;
@ -102,6 +104,7 @@ namespace MonoTests.System.Reflection
public Int64Enum field_Int64Enum;
public UInt64Enum field_UInt64Enum;
}
#pragma warning restore 649
public enum ByteEnum : byte
{
@ -376,10 +379,13 @@ namespace MonoTests.System.Reflection
Assert.AreEqual (typeof (Marshal1), Type.GetType (attr.MarshalType), "#I4");
}
// Disable "field not used warning", this is intended.
#pragma warning disable 649
class Foo {
public static int static_field;
public int field;
}
#pragma warning restore 649
[ExpectedException (typeof (ArgumentException))]
public void GetValueWrongObject ()
@ -1359,16 +1365,24 @@ namespace MonoTests.System.Reflection
}
// We do not refernece the field, that is expected
#pragma warning disable 169
// Helper classes
class RefOnlyFieldClass
{
// Helper property
static int RefOnlyField;
}
#pragma warning restore 169
class NonPublicFieldClass
{
protected int protectedField;
public void Dummy ()
{
protectedField = 1;
}
}
public class FieldInfoTest<T>

View File

@ -42,9 +42,12 @@ using System.Collections.Generic;
#endif
namespace A.B.C {
// Disable expected warning
#pragma warning disable 169
public struct MethodInfoTestStruct {
int p;
}
#pragma warning restore 169
}
namespace MonoTests.System.Reflection
{
@ -253,7 +256,7 @@ namespace MonoTests.System.Reflection
public struct SimpleStruct
{
int a;
public int a;
}
public static unsafe SimpleStruct* PtrFunc2 (SimpleStruct* a, A.B.C.MethodInfoTestStruct *b)

View File

@ -178,7 +178,7 @@ namespace MonoTests.System.Reflection.Emit
}
public class Bar<T> {
public class Foo<T> {}
public class Foo<U> {}
}
[Test]

View File

@ -29,6 +29,8 @@ using System;
using System.Reflection;
using NUnit.Framework;
// Various fields in this class are not used directly by the C# code, they are only here to be reflected upon
#pragma warning disable 649
namespace MonoTests.System.Reflection
{
[TestFixture]