#NEWLINE# def testGetDynSym( self ) : #NEWLINE# #INDENT# libPath = os . path . dirname ( elf . __file__ ) #NEWLINE# for soPrefix in [ 'elf' , 'ext/streams' , 'ext/file_utils' ] : #NEWLINE# #INDENT# fname = os . path . join ( libPath , ( soPrefix + '.so' ) ) #NEWLINE# syms = elf . getDynSym ( fname ) #NEWLINE# initfunc = ( 'init' + os . path . basename ( soPrefix ) ) #NEWLINE# self . assertTrue ( ( initfunc in syms ) , ( '%s not in %s' % ( initfunc , syms ) ) ) #NEWLINE# #UNINDENT# fname = os . path . join ( libPath , 'filename_wrapper.so' ) #NEWLINE# if os . path . exists ( fname ) : #NEWLINE# #INDENT# syms = elf . getDynSym ( fname ) #NEWLINE# self . assertTrue ( ( 'chdir' in syms ) ) #NEWLINE# #UNINDENT# fname = os . path . join ( resources . get_archive ( ) , 'basesystem-8.0-2.src.rpm' ) #NEWLINE# self . assertRaises ( elf . error , elf . getDynSym , fname )