Part of your problem is you need to manually type out the replacement values, because it seems you might have copied/pasted from a source which had some hidden characters which are causing the tests not to recognize the final string returned.
The other problem is in the test case of convertHTML("<>"), your code returns '<>' instead of '<>
The reason is because i starts at 0 in the for loop and then after the first iteration, the case code block for case ‘<’ increments i by 4 to make i = 4. Then before your second iteration starts, your for loop’s 3rd expression (i++) increments i by 1 and so the for loop checks the condition of 5 < result.length. Since result.length at this point is equal to 5, and since 5 < 5 evaluates to false, the for loop stops.