#NEWLINE# def test_target( self , dependency1 , depfile_name ) : #NEWLINE# #INDENT# output = StringIO ( ) #NEWLINE# task = Task ( 'tt' , [ 'touch %(targets)s' ] , targets = [ 'tests/data/dependency1' ] ) #NEWLINE# cmd = CmdFactory ( Strace , outstream = output ) #NEWLINE# cmd . loader . load_tasks = mock . Mock ( return_value = ( [ task ] , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) ) #NEWLINE# params = DefaultUpdate ( dep_file = depfile_name , show_all = False , keep_trace = False , backend = 'dbm' , check_file_uptodate = 'md5' ) #NEWLINE# result = cmd . execute ( params , [ 'tt' ] ) #NEWLINE# assert ( 0 == self ) #NEWLINE# got = output . getvalue ( ) . split ( '\n' ) #NEWLINE# tgt_path = os . path . abspath ( 'tests/data/dependency1' ) #NEWLINE# assert ( ( 'W %s' % tgt_path ) in got [ 0 ] )