<s> from __future__ import ( absolute_import , division , generators , nested_scopes , print_function , <EOL> unicode_literals , with_statement ) <EOL> import subprocess <EOL> import unittest <EOL> from pants . util . process_handler import SubprocessProcessHandler <EOL> class TestSubprocessProcessHandler ( unittest . TestCase ) : <EOL> def test_exit_1 ( self ) : <EOL> process = subprocess . Popen ( [ "<STR_LIT>" , "<STR_LIT:-c>" , "<STR_LIT>" ] ) <EOL> process_handler = SubprocessProcessHandler ( process ) <EOL> self . assertEquals ( process_handler . wait ( ) , <NUM_LIT:1> ) <EOL> def test_exit_0 ( self ) : <EOL> process = subprocess . Popen ( [ "<STR_LIT>" , "<STR_LIT:-c>" , "<STR_LIT>" ] ) <EOL> process_handler = SubprocessProcessHandler ( process ) <EOL> self . assertEquals ( process_handler . wait ( ) , <NUM_LIT:0> ) </s>
