<s> import os <EOL> import tempfile <EOL> from certfuzz . fuzztools . subprocess_helper import run_with_timer <EOL> from certfuzz . fuzztools . subprocess_helper import run_without_timer <EOL> '''<STR_LIT>''' <EOL> import unittest <EOL> class Test ( unittest . TestCase ) : <EOL> def delete_file ( self , f ) : <EOL> os . remove ( f ) <EOL> self . assertFalse ( os . path . exists ( f ) ) <EOL> def test_run_with_timer2 ( self ) : <EOL> ( fd , f ) = tempfile . mkstemp ( text = True ) <EOL> os . close ( fd ) <EOL> self . delete_file ( f ) <EOL> args = [ '<STR_LIT>' , f ] <EOL> timeout = <NUM_LIT:10> <EOL> run_with_timer ( args , timeout , '<STR_LIT>' ) <EOL> self . assertTrue ( os . path . exists ( f ) ) <EOL> self . delete_file ( f ) <EOL> run_with_timer ( args , timeout , '<STR_LIT>' , shell = True ) <EOL> self . assertTrue ( os . path . exists ( f ) ) <EOL> self . delete_file ( f ) <EOL> def test_run_without_timer ( self ) : <EOL> ( fd , f ) = tempfile . mkstemp ( text = True ) <EOL> os . close ( fd ) <EOL> self . delete_file ( f ) <EOL> run_without_timer ( '<STR_LIT>' % f ) <EOL> self . assertTrue ( os . path . exists ( f ) ) <EOL> self . delete_file ( f ) <EOL> def test_killall ( self ) : <EOL> pass <EOL> def test_kill ( self ) : <EOL> pass <EOL> if __name__ == "<STR_LIT:__main__>" : <EOL> unittest . main ( ) </s>
