improve wrapping for markdown
add wrapMethod:auto and fix tests