#NEWLINE# def test_get_only_proxy( self ) : #NEWLINE# #INDENT# class Something ( object ) : #NEWLINE# #INDENT# foo = 'foo' #NEWLINE# #UNINDENT# class SomethingElse ( ) : #NEWLINE# #INDENT# foo = 'foo' #NEWLINE# #UNINDENT# for thing in ( Something , SomethingElse , Something ( ) , SomethingElse ) : #NEWLINE# #INDENT# proxy = _get_proxy ( thing ) #NEWLINE# @ patch . object ( proxy , 'foo' , 'bar' ) #NEWLINE# def test( ) : #NEWLINE# #INDENT# self . assertEqual ( proxy . foo , 'bar' ) #NEWLINE# #UNINDENT# test ( ) #NEWLINE# self . assertEqual ( proxy . foo , 'foo' ) #NEWLINE# self . assertEqual ( thing . foo , 'foo' ) #NEWLINE# self . assertNotIn ( 'foo' , self . __dict__ )