mirror of
https://github.com/ivellioscolin/pykd.git
synced 2025-04-20 03:23:23 +08:00
[0.3.x] add: test for array of functions
git-svn-id: https://pykd.svn.codeplex.com/svn@86410 9b283d60-5439-405e-af05-b73fd8c4d996
This commit is contained in:
parent
260f9f8685
commit
b25a648464
@ -266,9 +266,22 @@ class TypeInfoTest( unittest.TestCase ):
|
|||||||
functype = target.module.typedVar( "MethodPtr" ).type().deref()
|
functype = target.module.typedVar( "MethodPtr" ).type().deref()
|
||||||
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::)()")
|
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::)()")
|
||||||
|
|
||||||
|
functype = target.module.typedVar( "ArrayOfCdeclFuncPtr" ).type()[0].deref()
|
||||||
|
self.assertEqual(functype.name(), "Void(__cdecl)(Int4B, Float)")
|
||||||
|
|
||||||
|
functype = target.module.typedVar( "ArrayOfMethodPtr" ).type()[0].deref()
|
||||||
|
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::)()")
|
||||||
|
|
||||||
def testFunctionPtrName(self):
|
def testFunctionPtrName(self):
|
||||||
funcptrtype = target.module.typedVar( "CdeclFuncPtr" ).type()
|
funcptrtype = target.module.typedVar( "CdeclFuncPtr" ).type()
|
||||||
self.assertEqual(funcptrtype.name(), "Void(__cdecl*)(Int4B, Float)")
|
self.assertEqual(funcptrtype.name(), "Void(__cdecl*)(Int4B, Float)")
|
||||||
|
|
||||||
functype = target.module.typedVar( "MethodPtr" ).type().deref()
|
functype = target.module.typedVar( "MethodPtr" ).type().deref()
|
||||||
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*)()")
|
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*)()")
|
||||||
|
|
||||||
|
def testFunctionArrName(self):
|
||||||
|
funcptrtype = target.module.typedVar( "ArrayOfCdeclFuncPtr" ).type()
|
||||||
|
self.assertEqual(funcptrtype.name(), "Void(__cdecl*[3])(Int4B, Float)")
|
||||||
|
|
||||||
|
functype = target.module.typedVar( "ArrayOfMethodPtr" ).type().deref()
|
||||||
|
self.assertEqual(functype.name(), "Void(__thiscall FuncTestClass::*[2])()")
|
||||||
|
Loading…
Reference in New Issue
Block a user