More todo.
Added failing test.
Fixed patch command so the test passes.
Return on first patching error.
Removed dead code.
Added comment.
More basic testing.