#NEWLINE# def test_distiller_with_catchall( self ) : #NEWLINE# #INDENT# c = distiller . Distiller ( self . valid_event_def1 , self . fake_plugin_map , catchall = True ) #NEWLINE# self . assertEqual ( 2 , len ( c . definitions ) ) #NEWLINE# e = c . to_event ( self . test_notification1 , TestCondenser ( ) ) #NEWLINE# self . assertIsValidEvent ( e , self . test_notification1 ) #NEWLINE# self . assertEqual ( 3 , len ( e . traits ) ) #NEWLINE# self . assertHasDefaultTraits ( e ) #NEWLINE# self . assertHasTrait ( e , 'instance_id' ) #NEWLINE# self . assertHasTrait ( e , 'host' ) #NEWLINE# e = c . to_event ( self . test_notification2 , TestCondenser ( ) ) #NEWLINE# self . assertIsValidEvent ( e , self . test_notification2 ) #NEWLINE# self . assertEqual ( 1 , len ( e . traits ) , ( 'Wrong number of traits %s: %s' % ( len ( e . traits ) , e . traits ) ) ) #NEWLINE# self . assertHasDefaultTraits ( e ) #NEWLINE# self . assertDoesNotHaveTrait ( e , 'instance_id' ) #NEWLINE# self . assertDoesNotHaveTrait ( e , 'host' )