But you could expect
ssh localhost sh -c 'cd /tmp && pwd'
to pass "sh -c 'cd /tmp && pwd'" over the network, which would trigger the expected behavior. But the arguments are not quoted so you end up with just: "sh -c cd /tmp && pwd".