I agree this change and the class in general needs more comprehensive tests. I'll add a couple more test cases as soon as I get a chance.