#NEWLINE# def test_refcounts( self ) : #NEWLINE# #INDENT# p = POINTER ( IUnknown ) ( ) #NEWLINE# windll . oleaut32 . CreateTypeLib2 ( 1 , 'blabla' , byref ( p ) ) #NEWLINE# for i in range ( 2 , 10 ) : #NEWLINE# #INDENT# self . failUnlessEqual ( p . AddRef ( ) , i ) #NEWLINE# #UNINDENT# for i in range ( 8 , 0 , ( - 1 ) ) : #NEWLINE# #INDENT# self . failUnlessEqual ( p . Release ( ) , p )