source: trunk/ab5.0/ablib/TestCase/SimpleTestCase/GCHandleTest.ab@ 656

Last change on this file since 656 was 656, checked in by イグトランス (egtra), 15 years ago

文字列比較のテストを3引数版UnitTestの呼出に変更

File size: 564 bytes
Line 
1'--------------------------------------------------------------------
2' Test case of GCHandle Class
3'--------------------------------------------------------------------
4
5Namespace GCHandleTest
6
7Sub TestMain()
8 Imports System.Runtime.InteropServices
9
10 Dim o = New Object
11 Dim gch = GCHandle.Alloc(o)
12 UnitTest("GCHandle.Alloc, Target", o.Equals(gch.Target))
13
14 Dim ip = GCHandle.ToIntPtr(gch)
15 gch = Nothing
16
17 gch = GCHandle.FromIntPtr(ip)
18 UnitTest("GCHandle - IntPtr", o.Equals(gch.Target))
19End Sub
20
21End Namespace
22
23'GCHandleTest.TestMain()
Note: See TracBrowser for help on using the repository browser.