#NEWLINE# def test_create_rule( self ) : #NEWLINE# #INDENT# 'Test creating Rule objects in various ways\n        ' #NEWLINE# r1 = Rule ( { #NEWLINE# #INDENT# 'chain' : 'INPUT' , #NEWLINE# 'source' : '1.2.3.4' , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . assertEquals ( str ( r3 ) , "Rule(chain='INPUT', num=None, pkts=None, bytes=None, target=None, prot='all', opt='--', inp='*', out='*', source='1.2.3.4', destination='0.0.0.0/0', extra='')" ) #NEWLINE# r2 = Rule ( chain = 'INPUT' , num = None , pkts = None , bytes = None , target = None , prot = 'all' , opt = '--' , inp = '*' , out = '*' , source = '1.2.3.4' , destination = '0.0.0.0/0' , extra = '' ) #NEWLINE# self . assertEquals ( str ( r2 ) , "Rule(chain='INPUT', num=None, pkts=None, bytes=None, target=None, prot='all', opt='--', inp='*', out='*', source='1.2.3.4', destination='0.0.0.0/0', extra='')" ) #NEWLINE# r3 = Rule ( [ 'INPUT' , None , None , None , None , 'all' , '--' , '*' , '*' , '1.2.3.4' , '0.0.0.0/0' , '' ] ) #NEWLINE# self . assertEquals ( str ( r3 ) , "Rule(chain='INPUT', num=None, pkts=None, bytes=None, target=None, prot='all', opt='--', inp='*', out='*', source='1.2.3.4', destination='0.0.0.0/0', extra='')" )