#NEWLINE# def test_exe( self ) : #NEWLINE# #INDENT# ps_pathname = ps ( ( 'ps --no-headers -o command -p %s' % self . pid ) ) . split ( ' ' ) [ 0 ] #NEWLINE# psutil_pathname = psutil . Process ( self . pid ) . exe ( ) #NEWLINE# try : #NEWLINE# #INDENT# self . assertEqual ( ps_pathname , psutil_pathname ) #NEWLINE# #UNINDENT# except AssertionError : #NEWLINE# #INDENT# adjusted_ps_pathname = ps_pathname [ : len ( ps_pathname ) ] #NEWLINE# self . assertEqual ( ps_pathname , adjusted_ps_pathname )