#NEWLINE# def testCompletion( self ) : #NEWLINE# #INDENT# "Tests '[[]]' syntax replacement." #NEWLINE# indx = clitable . CliTable ( ) #NEWLINE# self . failUnlessEqual ( 'abc' , re . sub ( '(\\[\\[.+?\\]\\])' , indx . _Completion , 'abc' ) ) #NEWLINE# self . failUnlessEqual ( 'a(b(c)?)?' , re . sub ( '(\\[\\[.+?\\]\\])' , self . _Completion , 'a[[bc]]' ) ) #NEWLINE# self . failUnlessEqual ( 'a(b(c)?)? de(f)?' , re . sub ( '(\\[\\[.+?\\]\\])' , indx . _Completion , 'a[[bc]] de[[f]]' ) )