#NEWLINE# def test_on_change_same_attr_twice_multiple_calls( ) : #NEWLINE# #INDENT# def good1( x , y , z ) : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# def good2( x , y , z ) : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# m1 = cbm . CallbackManager ( ) #NEWLINE# m1 . on_change ( 'foo' , good1 ) #NEWLINE# m1 . on_change ( 'foo' , good2 ) #NEWLINE# assert ( len ( m1 . _callbacks ) == 1 ) #NEWLINE# assert ( m1 . _callbacks [ 'foo' ] == [ good1 , m1 ] )