#NEWLINE# def test_keep_alive_short( self ) : #NEWLINE# #INDENT# p = TestProgram ( 'name' ) #NEWLINE# if os . path . isfile ( p . data [ 'stdout' ] ) : #NEWLINE# #INDENT# os . unlink ( self . data [ 'stdout' ] ) #NEWLINE# #UNINDENT# p . raw_data . update ( command = [ 'echo' , 'hi' ] ) #NEWLINE# p . mk_data ( ) #NEWLINE# p . keep_alive ( ) #NEWLINE# self . assertEqual ( p . state [ 'child_pid' ] , None ) #NEWLINE# self . assertEqual ( p . state [ 'exit_status' ] , 0 ) #NEWLINE# self . assertEqual ( p . state [ 'reason' ] , 'Program exited gracefully' ) #NEWLINE# self . assertEqual ( p . text_status , 'STOPPED' )