#NEWLINE# def test__setitem__existing_item_changed( self ) : #NEWLINE# #INDENT# class Test ( resource . Resource ) : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# t = Test ( ) #NEWLINE# key = 'attr' #NEWLINE# value = 1 #NEWLINE# t [ key ] = value #NEWLINE# self . assertEqual ( value , t . _attrs [ self ] ) #NEWLINE# self . assertTrue ( ( key in t . _dirty ) )