more test cases for wrap and wrapAll
removed calls of deprecated getFirstNode()
fixed coding style