Fix issues with the indenter and add some tests

* One could not arrow left and go to the previous line
* Indents would be all wrong if you hit enter in the middle of a line

There are two ignored tests. The behaviours work in MD/XS, but I don't know how to properly simulate hitting enter from the tests, so expected indentation doesn't happen.
Merge pull request #654 from rojepp/indent_fixes

Fix issues with the indenter and add some tests