def testShell(self, systemMock): """Test a simple shell command.""" command = ['/bin/ls'] shell = Shell('bah', command=command) shell._execute(FrameSet('5-6')) systemMock.assert_has_calls([ mock.call(command, frame=5), mock.call(command, frame=6), ])
def testShellToString(self, systemMock): """Test a string shell command.""" command = '/bin/ls -l ./' shell = Shell('bah', command=command) shell._execute(FrameSet('5-6')) systemMock.assert_has_calls([ mock.call(command, frame=5), mock.call(command, frame=6), ])