2009-02-21 Zoltan Varga <vargaz@gmail.com>
authorZoltan Varga <vargaz@gmail.com>
Sat, 21 Feb 2009 21:31:56 +0000 (21:31 -0000)
committerZoltan Varga <vargaz@gmail.com>
Sat, 21 Feb 2009 21:31:56 +0000 (21:31 -0000)
* invoke.cs: Add a test.

svn path=/trunk/mono/; revision=127639

mono/tests/ChangeLog
mono/tests/invoke.cs

index 9500d1ce58d8e057b5f31df9df1dbe2b4d6f5cad..039c4c983095fbeffc2d2078885d361cdc6ba233 100644 (file)
@@ -1,3 +1,7 @@
+2009-02-21  Zoltan Varga  <vargaz@gmail.com>
+
+       * invoke.cs: Add a test.
+
 2009-02-19  Zoltan Varga  <vargaz@gmail.com>
 
        * pinvoke2.cs libtest.c: Add a test for #477396.
index 94546f187353919519d87b46fafbc4d4d1c82ce6..9add9a0bc0aaa7758ffa40336ba2168651d575e0 100644 (file)
@@ -78,6 +78,11 @@ class Test {
                string s = (string)arr.GetType ().GetMethod ("Get").Invoke (arr, new object [] { 1, 1 });
                if (s != "FOO")
                        return 3;
+
+               // Test the sharing of runtime invoke wrappers for string ctors
+               typeof (string).GetConstructor (new Type [] { typeof (char[]) }).Invoke (null, new object [] { new char [] { 'a', 'b', 'c' } });
+
+               typeof (Assembly).GetMethod ("GetType", new Type [] { typeof (string), }).Invoke (typeof (int).Assembly, new object [] { "A" });
        
                return 0;
        }