diff --git a/procs.py b/procs.py index 4c0e362..317aee2 100644 --- a/procs.py +++ b/procs.py @@ -79,6 +79,9 @@ class Process(object): return Chain([self, other]) + def __repr__(self): + return ''.format(command=self.command) + class Chain(object): diff --git a/tests/test_process.py b/tests/test_process.py index 5ebe897..a166045 100644 --- a/tests/test_process.py +++ b/tests/test_process.py @@ -7,6 +7,10 @@ TEST_DIR = os.path.abspath(os.path.join( os.path.dirname(os.path.abspath(__file__)), 'test_data' )) +def tests_repr(): + p = Process('foo') + assert repr(p) == '' + def test_single_proc(): ls = Process('ls {test_dir}'.format(test_dir=TEST_DIR))