'Test shell wrapping for Docker chdir'

def test_wrapped_command(self):

    cmd = DockerBuildCommand(['pip', 'install', 'requests'], cwd='/tmp/foobar')
    self.assertEqual(cmd.get_wrapped_command(), "/bin/sh    -c    'cd    /tmp/foobar    &&    pip    install    requests'")
    cmd = DockerBuildCommand(['python', '/tmp/foo/pip', 'install', 'Django>1.7'], cwd='/tmp/foobar', bin_path='/tmp/foo')
    self.assertEqual(cmd.get_wrapped_command(), "/bin/sh    -c    'cd    /tmp/foobar    &&    PATH=/tmp/foo:$PATH    python    /tmp/foo/pip    install    Django\\>1.7'")
